Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 676ed9d

Browse filesBrowse files
Anna Piechowskiengelke
authored andcommitted
Move import statment inside sample (GoogleCloudPlatform#1948)
* Move import statment inside sample Import statement does not appear inside [this sample](https://cloud.google.com/functions/docs/env-var#functions_env_var_access-python). Makes the published sample misleading because it won't work as-is. * Linter fix
1 parent 2094cb4 commit 676ed9d
Copy full SHA for 676ed9d

File tree

Expand file treeCollapse file tree

1 file changed

+2
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+2
-1
lines changed

‎functions/env_vars/main.py

Copy file name to clipboardExpand all lines: functions/env_vars/main.py
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,11 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15+
16+
# [START functions_env_vars]
1517
import os
1618

1719

18-
# [START functions_env_vars]
1920
def env_vars(request):
2021
return os.environ.get('FOO', 'Specified environment variable is not set.')
2122
# [END functions_env_vars]

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.