Commit 116bcf73 authored by AUTOMATIC's avatar AUTOMATIC
Browse files

disable setting options via API until it is fixed by the author

parent f316280a
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -218,6 +218,10 @@ class Api:
        return options
        
    def set_config(self, req: OptionsModel):
        # currently req has all options fields even if you send a dict like { "send_seed": false }, which means it will
        # overwrite all options with default values.
        raise RuntimeError('Setting options via API is not supported')

        reqDict = vars(req)
        for o in reqDict:
            setattr(shared.opts, o, reqDict[o])