diff options
| author | Gertjan van den Burg <gertjanvandenburg@gmail.com> | 2019-08-19 16:32:28 +0100 |
|---|---|---|
| committer | Gertjan van den Burg <gertjanvandenburg@gmail.com> | 2019-08-19 16:32:28 +0100 |
| commit | b1f18230a23ad13d253525f7d9ba81bb56ee4f94 (patch) | |
| tree | 6702121a6030806823f76905e63a1bbdb2c89cd1 | |
| parent | Text changes (diff) | |
| download | AnnotateChange-b1f18230a23ad13d253525f7d9ba81bb56ee4f94.tar.gz AnnotateChange-b1f18230a23ad13d253525f7d9ba81bb56ee4f94.zip | |
Code quality
| -rw-r--r-- | app/main/demo.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/app/main/demo.py b/app/main/demo.py index 7e21768..2c0f1bc 100644 --- a/app/main/demo.py +++ b/app/main/demo.py @@ -336,10 +336,9 @@ def process_annotations(demo_id): ) return redirect(url_for("main.index")) - if annotation["changepoints"] is None: - retval = [] - else: - retval = [cp["x"] for cp in annotation["changepoints"]] + retval = [] + if not annotation["changepoints"] is None: + retval = [int(cp["x"]) for cp in annotation["changepoints"]] # If the user is already introduced, we assume that their demo annotations # are already in the database, and thus we don't put them back in (because |
