public async Task SetScriptTranslation(string languageCode, ScriptResource scriptResource) { if (Languages.ContainsKey(languageCode) && Languages[languageCode] != scriptResource.DefaultLanguage) { var scriptTranslation = await _translationRepository.GetScriptTranslation(scriptResource.Id, Languages[languageCode]); if (scriptTranslation == null) { return; } if (scriptTranslation.Name != null) { scriptResource.Name = scriptTranslation.Name; } if (scriptTranslation.Description != null) { scriptResource.Description = scriptTranslation.Description; } if (scriptTranslation.Notes != null) { scriptResource.Notes = scriptTranslation.Notes; } } return; }