aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPjotr Prins2016-06-26 09:55:16 +0000
committerPjotr Prins2016-06-26 09:55:16 +0000
commit7d6a2dcece8df158b52caf04b3f0dbde23181c93 (patch)
tree60105a4114f5620e0586bd372be70160e40f498a
parente5db09b6da841eb077335a50c2dba1326d8dd670 (diff)
downloadgenenetwork2-7d6a2dcece8df158b52caf04b3f0dbde23181c93.tar.gz
gn_server: simplify
-rw-r--r--wqflask/base/data_set.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/wqflask/base/data_set.py b/wqflask/base/data_set.py
index e0bf5f40..d0ec3f3c 100644
--- a/wqflask/base/data_set.py
+++ b/wqflask/base/data_set.py
@@ -477,8 +477,6 @@ class DataSet(object):
"""
- def helper(r):
- return r["id"],r["name"],r["full_name"],r["short_name"],r["data_scale"],r["tissue"]
try:
if self.type == "ProbeSet":
@@ -495,7 +493,9 @@ WHERE ProbeSetFreeze.public > %s
AND ProbeSetFreeze.ProbeFreezeId = ProbeFreeze.Id
AND ProbeFreeze.TissueId = Tissue.Id
AND (ProbeSetFreeze.Name = '%s' OR ProbeSetFreeze.FullName = '%s' OR ProbeSetFreeze.ShortName = '%s')
- """ % (query_args),"/dataset/"+self.name+".json",helper)
+ """ % (query_args),"/dataset/"+self.name+".json",
+ lambda r: (r["id"],r["name"],r["full_name"],r["short_name"],r["data_scale"],r["tissue"])
+ )
else:
query_args = tuple(escape(x) for x in (
(self.type + "Freeze"),