mirror of
https://github.com/mitb-archive/filebot
synced 2024-12-23 08:18:52 -05:00
Experiment with PGP signed messages
This commit is contained in:
parent
a0d9ca6452
commit
659e25b5ce
@ -8,6 +8,8 @@ public enum LicenseModel {
|
|||||||
|
|
||||||
MicrosoftStore {
|
MicrosoftStore {
|
||||||
|
|
||||||
|
private final Resource<Boolean> CHECK = Resource.lazy(() -> !getAppUserModelID().equals("PointPlanck.FileBot"));
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isAppStore() {
|
public boolean isAppStore() {
|
||||||
return true;
|
return true;
|
||||||
@ -15,14 +17,20 @@ public enum LicenseModel {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void check() throws LicenseError {
|
public void check() throws LicenseError {
|
||||||
if (!getAppUserModelID().equals("PointPlanck.FileBot")) {
|
try {
|
||||||
|
if (CHECK.get()) {
|
||||||
throw new LicenseError("Microsoft Store: Desktop Bridge not found");
|
throw new LicenseError("Microsoft Store: Desktop Bridge not found");
|
||||||
}
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
throw new IllegalStateException(e);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
MacAppStore {
|
MacAppStore {
|
||||||
|
|
||||||
|
private final Resource<Boolean> CHECK = Resource.lazy(() -> !File.listRoots()[0].canRead());
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isAppStore() {
|
public boolean isAppStore() {
|
||||||
return true;
|
return true;
|
||||||
@ -30,8 +38,12 @@ public enum LicenseModel {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void check() throws LicenseError {
|
public void check() throws LicenseError {
|
||||||
if (File.listRoots()[0].canRead()) {
|
try {
|
||||||
throw new LicenseError("Mac App Store: App Sandbox not found");
|
if (CHECK.get()) {
|
||||||
|
throw new LicenseError("Microsoft Store: Desktop Bridge not found");
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
throw new IllegalStateException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user