/// <summary> /// Decrypts instance of <typeparamref name="T"/> from file system. /// </summary> /// <param name="targetFileName"> /// Contains <see cref="string"/> value with target file name. /// </param> /// <param name="passphrase"> /// Contains <see cref="string"/> value with passphrase. /// </param> /// <returns> /// Returns instance of <typeparamref name="T"/>. /// </returns> public static T DecryptInstance(string targetFileName, string passphrase) { if (!string.IsNullOrEmpty(targetFileName)) { try { var configuration = CoreSyncConfiguration.SingletonInstance; return(Deserialize(DataProcessor.Decrypt(targetFileName, passphrase))); } catch (Exception e) { CoreSyncProcessor.Log(e); } } return(default);