internal void OnScriptingSaved(ScriptingDataSavedResponse message) { if (ScriptingSaved == null) return; if (string.IsNullOrEmpty(message.Error)) { try { ScriptingSaved(this, new EventArgs<ScriptingSavedEventArgs>( new ScriptingSavedEventArgs(message.Parameters.Select(DataConverter.ToClientParameter), message.Path, DataConverter.ToClientScriptingType(message.ScriptingType)))); } catch (Exception ex) { Logger.Error(ex); } } else { if (!string.IsNullOrWhiteSpace(message.Error)) ScriptingMessage?.Invoke(this, new EventArgs<string>(message.Error)); } }
internal void OnScriptingDataRemove(ScriptingDataRemoveResponse message) { if (!string.IsNullOrWhiteSpace(message.Error)) ScriptingMessage?.Invoke(this, new EventArgs<string>(message.Error)); }