@lvce-editor/main-process 6.37.11 → 6.37.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5837,13 +5837,20 @@ const stop = id => {
5837
5837
 
5838
5838
  const Base64 = 'base64';
5839
5839
 
5840
+ const ensureEncryptionAvailable = () => {
5841
+ if (!safeStorage.isEncryptionAvailable() && isLinux) {
5842
+ safeStorage.setUsePlainTextEncryption(true);
5843
+ }
5844
+ };
5840
5845
  const isEncryptionAvailable = () => {
5841
5846
  return safeStorage.isEncryptionAvailable();
5842
5847
  };
5843
5848
  const encrypt = plainText => {
5849
+ ensureEncryptionAvailable();
5844
5850
  return safeStorage.encryptString(plainText).toString(Base64);
5845
5851
  };
5846
5852
  const decrypt = encrypted => {
5853
+ ensureEncryptionAvailable();
5847
5854
  const buffer = Buffer.from(encrypted, Base64);
5848
5855
  return safeStorage.decryptString(buffer);
5849
5856
  };
@@ -6403,7 +6410,9 @@ const handler$7 = (_event, webContentsId) => {
6403
6410
  view
6404
6411
  } = instance;
6405
6412
  remove(webContentsId);
6406
- browserWindow.contentView.removeChildView(view);
6413
+ if (!browserWindow.isDestroyed()) {
6414
+ browserWindow.contentView.removeChildView(view);
6415
+ }
6407
6416
  }
6408
6417
  return {
6409
6418
  messages,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lvce-editor/main-process",
3
- "version": "6.37.11",
3
+ "version": "6.37.13",
4
4
  "keywords": [
5
5
  "lvce-editor",
6
6
  "electron"