etr2460 commented on a change in pull request #13992:
URL: https://github.com/apache/superset/pull/13992#discussion_r608980195



##########
File path: superset/security/manager.py
##########
@@ -1125,3 +1132,20 @@ def raise_for_dashboard_access(self, dashboard: 
"Dashboard") -> None:
 
             if not can_access:
                 raise DashboardAccessDeniedError()
+
+    # pylint: disable=no-self-use
+    def can_access_based_on_dashboard(self, datasource: "BaseDatasource"):
+        from superset import db
+        from superset.dashboards.filters import DashboardFilter
+        from superset.models.slice import Slice
+        from superset.models.dashboard import Dashboard
+
+        TBL = ConnectorRegistry.sources["table"]

Review comment:
       won't this still break if you pass in a Druid Datasource? you'll be 
trying to find a table with the same id as the druid datasource




-- 
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.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to