rusackas commented on code in PR #37009:
URL: https://github.com/apache/superset/pull/37009#discussion_r3538273840
##########
superset/views/base.py:
##########
@@ -35,7 +35,7 @@
)
from flask_appbuilder import BaseView, Model, ModelView
from flask_appbuilder.actions import action
-from flask_appbuilder.const import AUTH_OAUTH
+from flask_appbuilder.const import AUTH_LDAP, AUTH_OAUTH
Review Comment:
AUTH_OAUTH and AUTH_SAML already come from that same import with no
fallback, and AUTH_LDAP is just as old a FAB constant — wrapping only this one
would be inconsistent.
##########
superset/views/base.py:
##########
@@ -479,7 +479,7 @@ def cached_common_bootstrap_data( # pylint:
disable=unused-argument
auth_type = app.config["AUTH_TYPE"]
auth_user_registration = app.config["AUTH_USER_REGISTRATION"]
frontend_config["AUTH_USER_REGISTRATION"] = auth_user_registration
- should_show_recaptcha = auth_user_registration and (auth_type !=
AUTH_OAUTH)
+ should_show_recaptcha = auth_user_registration and (auth_type not in
[AUTH_OAUTH, AUTH_LDAP])
Review Comment:
The existing check already compares against these constants directly with no
normalization, so guarding just the LDAP case would be inconsistent. Leaving
as-is.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]