Skip to content

Commit

Permalink
improve formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
chicco785 committed Sep 29, 2020
1 parent 217376f commit 85a36c3
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/translators/sql_translator.py
Original file line number Diff line number Diff line change
Expand Up @@ -539,7 +539,8 @@ def _get_where_clause(self, entity_ids, from_date, to_date, fiware_sp=None,
" " + FIWARE_SERVICEPATH + " ~* '($|/.*)'")
else:
clauses.append(
" " + FIWARE_SERVICEPATH + " ~* '" + fiware_sp + "($|/.*)'")
" " + FIWARE_SERVICEPATH + " ~* '"
+ fiware_sp + "($|/.*)'")
else:
# Match prefix of fiware service path
clauses.append(" " + FIWARE_SERVICEPATH + " = ''")
Expand Down Expand Up @@ -811,8 +812,8 @@ def query(self,
try:
self.cursor.execute(op)
except Exception as e:
#TODO due to this except in case of sql errors,
#all goes fine, and users gets 404 as result
# TODO due to this except in case of sql errors,
# all goes fine, and users gets 404 as result
# Reason 1: fiware_service_path column in legacy dbs.
logging.error("{}".format(e))
entities = []
Expand Down

0 comments on commit 85a36c3

Please sign in to comment.