aboutsummaryrefslogtreecommitdiff
path: root/wqflask/base/trait.py
diff options
context:
space:
mode:
authorzsloan2021-03-03 19:13:19 +0000
committerzsloan2021-03-03 19:13:19 +0000
commitdffcbc4d0c7370492ff976dae5f21bd06a621bc3 (patch)
tree1c347035105f2dc9b4034bca99291bee9eedc9f7 /wqflask/base/trait.py
parentf132a7376e5ece48c03166cd9f85271d8514eecd (diff)
downloadgenenetwork2-dffcbc4d0c7370492ff976dae5f21bd06a621bc3.tar.gz
Checked if pre_publication_description is NULL, because there was an error resulting from a trait missing both pre_publication_description and pubmed ID
Diffstat (limited to 'wqflask/base/trait.py')
-rw-r--r--wqflask/base/trait.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/wqflask/base/trait.py b/wqflask/base/trait.py
index 41e2603c..df96d46e 100644
--- a/wqflask/base/trait.py
+++ b/wqflask/base/trait.py
@@ -516,10 +516,11 @@ def retrieve_trait_info(trait, dataset, get_qtl_info=False):
# If the dataset is confidential and the user has access to confidential
# phenotype traits, then display the pre-publication description instead
# of the post-publication description
- trait.description_display = ""
+ trait.description_display = "N/A"
if not trait.pubmed_id:
trait.abbreviation = trait.pre_publication_abbreviation
- trait.description_display = trait.pre_publication_description
+ if trait.pre_publication_description:
+ trait.description_display = trait.pre_publication_description
else:
trait.abbreviation = trait.post_publication_abbreviation
if description: