mirror of https://github.com/apache/superset.git
Return 401 on no authorization
This commit is contained in:
parent
5e6efae155
commit
9827925015
|
@ -2340,7 +2340,7 @@ class Superset(BaseSupersetView):
|
||||||
query.sql, query.database, query.schema)
|
query.sql, query.database, query.schema)
|
||||||
if rejected_tables:
|
if rejected_tables:
|
||||||
return json_error_response(security_manager.get_table_access_error_msg(
|
return json_error_response(security_manager.get_table_access_error_msg(
|
||||||
'{}'.format(rejected_tables)))
|
'{}'.format(rejected_tables)), status=401)
|
||||||
|
|
||||||
return json_success(utils.zlib_decompress_to_string(blob))
|
return json_success(utils.zlib_decompress_to_string(blob))
|
||||||
|
|
||||||
|
@ -2383,7 +2383,8 @@ class Superset(BaseSupersetView):
|
||||||
if rejected_tables:
|
if rejected_tables:
|
||||||
return json_error_response(
|
return json_error_response(
|
||||||
security_manager.get_table_access_error_msg(rejected_tables),
|
security_manager.get_table_access_error_msg(rejected_tables),
|
||||||
link=security_manager.get_table_access_link(rejected_tables))
|
link=security_manager.get_table_access_link(rejected_tables),
|
||||||
|
status=401)
|
||||||
session.commit()
|
session.commit()
|
||||||
|
|
||||||
select_as_cta = request.form.get('select_as_cta') == 'true'
|
select_as_cta = request.form.get('select_as_cta') == 'true'
|
||||||
|
|
Loading…
Reference in New Issue