Browse Source

Return setting value if value is not encrypted

pull/21744/head
liangshiwei 1 year ago
parent
commit
7d29671976
  1. 6
      framework/src/Volo.Abp.Settings/Volo/Abp/Settings/SettingEncryptionService.cs

6
framework/src/Volo.Abp.Settings/Volo/Abp/Settings/SettingEncryptionService.cs

@ -38,9 +38,15 @@ public class SettingEncryptionService : ISettingEncryptionService, ITransientDep
{
return StringEncryptionService.Decrypt(encryptedValue);
}
catch (FormatException)
{
// not an encrypted value, return the original value
return encryptedValue;
}
catch (Exception e)
{
Logger.LogException(e);
return string.Empty;
}
}

Loading…
Cancel
Save