From 23a247a50b2917c1287a2bf0adf4f91707f26569 Mon Sep 17 00:00:00 2001 From: Andrew Grimberg Date: Tue, 2 Jul 2019 15:23:01 -0700 Subject: [PATCH] Fix retyping issue of function There was a subtle bug where a function call was being overwritten by a local variable of the same name and then a call to the function was being attempted. Change-Id: I7316df0c773db347ccb1e7eb79e2f40fee3a9db2 Signed-off-by: Andrew Grimberg --- lftools/lfidapi.py | 4 ++-- releasenotes/notes/lfidapi-type-error-fix-aff74c5a7ea11a34.yaml | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) create mode 100644 releasenotes/notes/lfidapi-type-error-fix-aff74c5a7ea11a34.yaml diff --git a/lftools/lfidapi.py b/lftools/lfidapi.py index 3033c135..05a6a825 100755 --- a/lftools/lfidapi.py +++ b/lftools/lfidapi.py @@ -87,8 +87,8 @@ def helper_invite(email, group): def helper_create_group(group): """Create group.""" - check_response_code = helper_check_group_exists(group) - if check_response_code == 200: + response_code = helper_check_group_exists(group) + if response_code == 200: print("Group {} already exists exiting...".format(group)) else: access_token, url = oauth_helper() diff --git a/releasenotes/notes/lfidapi-type-error-fix-aff74c5a7ea11a34.yaml b/releasenotes/notes/lfidapi-type-error-fix-aff74c5a7ea11a34.yaml new file mode 100644 index 00000000..423f15a4 --- /dev/null +++ b/releasenotes/notes/lfidapi-type-error-fix-aff74c5a7ea11a34.yaml @@ -0,0 +1,6 @@ +--- +fixes: + - | + There was a subtle bug where a function call was being overwritten by a + local variable of the same name and then a call to the function was + being attempted. -- 2.16.6