Commit 9c6917f7 authored by C. Albrecht's avatar C. Albrecht
Browse files

FIX: Crash caused by accessing undefind variable

parent be3d879e
......@@ -85,12 +85,12 @@ def create_person(token, verbose=False):
def create_thing_in_repo(config, thing_id):
"""Creates a copy of an existing thing in ditto repository."""
res = config.create_cloud_copy(thing_id)
res = response.json()
status_code = res.status_code
if status_code == 201:
print("A copy has been successfully created.")
print("An error occured: {}".format(status_code))
def create_thing_in_directory(config, with_broker):
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment