Refactored Command to add owner
This commit is contained in:
@@ -33,7 +33,10 @@ class UserProfileState:
|
||||
|
||||
class Commands(BaseCommands):
|
||||
def update_dark_mode(self):
|
||||
return Command("UpdateDarkMode", "Set the dark mode", self._owner.update_dark_mode).htmx(target=None)
|
||||
return Command("UpdateDarkMode",
|
||||
"Set the dark mode",
|
||||
self._owner,
|
||||
self._owner.update_dark_mode).htmx(target=None)
|
||||
|
||||
|
||||
class UserProfile(SingleInstance):
|
||||
|
||||
Reference in New Issue
Block a user