We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 69de070 commit 1316ff8Copy full SHA for 1316ff8
src/webview/subscriptions/views.py
@@ -155,10 +155,7 @@ def post(self, request: HttpRequest) -> HttpResponse:
155
156
profile = request.user.profile
157
158
- if action == "enable":
159
- profile.auto_subscribe_to_maintained_packages = True
160
- else: # disable
161
- profile.auto_subscribe_to_maintained_packages = False
+ profile.auto_subscribe_to_maintained_packages = action == "enable"
162
163
profile.save(update_fields=["auto_subscribe_to_maintained_packages"])
164
0 commit comments