os.Getenv
This function will return value if Env var exists or return empty string if not. So it is difficult to gather if Env var value is empty or Env var is not exists.
This function will return value if Env var exists or return empty string if not. So it is difficult to gather if Env var value is empty or Env var is not exists.
os.LookupEnv
To overcome above problem, this function will check if Env var existence and return either value or the error.
To overcome above problem, this function will check if Env var existence and return either value or the error.
No comments:
Post a Comment