diff --git a/tests/test_settings.py b/tests/test_settings.py index 2ebd4c8..5f0d158 100644 --- a/tests/test_settings.py +++ b/tests/test_settings.py @@ -28,6 +28,10 @@ class TestSettings(UptimeKumaTestCase): r = self.api.set_settings(self.password, **expected_settings) self.assertEqual(r["msg"], "Saved") + # set settings without password + r = self.api.set_settings(**expected_settings) + self.assertEqual(r["msg"], "Saved") + # get settings settings = self.api.get_settings() self.compare(settings, expected_settings) diff --git a/uptime_kuma_api/api.py b/uptime_kuma_api/api.py index 0e027d8..a8177df 100644 --- a/uptime_kuma_api/api.py +++ b/uptime_kuma_api/api.py @@ -853,7 +853,7 @@ class UptimeKumaApi(object): def set_settings( self, - password: str, + password: str = None, # only required if disableAuth is true # about checkUpdate: bool = True,