// Override to load legacy config format public override void LoadFromSavedConfiguration(JToken jsonConfig) { var json = jsonConfig.ToString(); configData = JsonConvert.DeserializeObject <ConfigurationDataRuTor>(json); IsConfigured = true; }
public async Task ApplyConfiguration(JToken configJson) { configData.LoadValuesFromJson(configJson); var oldConfig = configData; var releases = await PerformQuery(new TorznabQuery()); await ConfigureIfOK(string.Empty, releases.Count() > 0, () => { configData = oldConfig; throw new Exception("Could not find releases from this URL"); }); }
public async Task<IndexerConfigurationStatus> ApplyConfiguration(JToken configJson) { configData.LoadValuesFromJson(configJson); var oldConfig = configData; var releases = await PerformQuery(new TorznabQuery()); await ConfigureIfOK(string.Empty, releases.Count() > 0, () => { configData = oldConfig; throw new Exception("Could not find releases from this URL"); }); return IndexerConfigurationStatus.RequiresTesting; }
// Override to load legacy config format public override void LoadFromSavedConfiguration(JToken jsonConfig) { var json = jsonConfig.ToString(); configData = JsonConvert.DeserializeObject<ConfigurationDataRuTor>(json); IsConfigured = true; }