mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Fixed code smell 'String literals should not be duplicated'.
This commit is contained in:
committed by
Akshay Joshi
parent
974d395a48
commit
31bbdd6a12
@@ -27,6 +27,7 @@ from pgadmin.utils.ajax import make_json_response, internal_server_error
|
||||
from pgadmin.utils.driver import get_driver
|
||||
from pgadmin.utils.exception import ConnectionLost, SSHTunnelConnectionLost,\
|
||||
CryptKeyMissing
|
||||
from pgadmin.utils.constants import ERROR_MSG_TRANS_ID_NOT_FOUND
|
||||
|
||||
|
||||
class StartRunningQuery:
|
||||
@@ -173,7 +174,7 @@ class StartRunningQuery:
|
||||
if 'gridData' not in http_session:
|
||||
return make_json_response(
|
||||
success=0,
|
||||
errormsg=gettext('Transaction ID not found in the session.'),
|
||||
errormsg=ERROR_MSG_TRANS_ID_NOT_FOUND,
|
||||
info='DATAGRID_TRANSACTION_REQUIRED', status=404
|
||||
)
|
||||
grid_data = http_session['gridData']
|
||||
@@ -181,7 +182,7 @@ class StartRunningQuery:
|
||||
if str(transaction_id) not in grid_data:
|
||||
return make_json_response(
|
||||
success=0,
|
||||
errormsg=gettext('Transaction ID not found in the session.'),
|
||||
errormsg=ERROR_MSG_TRANS_ID_NOT_FOUND,
|
||||
info='DATAGRID_TRANSACTION_REQUIRED',
|
||||
status=404
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user