rusackas commented on code in PR #38615:
URL: https://github.com/apache/superset/pull/38615#discussion_r3409325052


##########
superset/commands/dashboard/importers/v1/utils.py:
##########
@@ -241,7 +241,7 @@ def import_dashboard(  # noqa: C901
     if dashboard.id is None:
         db.session.flush()
 
-    if (user := get_user()) and user not in dashboard.owners:
+    if not existing and (user := get_user()) and user not in dashboard.owners:

Review Comment:
   Good catch — `user` is already bound up top, so I dropped the walrus and 
just reuse it.



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

Reply via email to