@ianua/ianus-dataverse-react-fluentui8 1.0.11 → 1.0.12
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.
- package/dist/index.js +34 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -516,7 +516,7 @@ var fetchOrganizationIdFromWebApi = (webApi) => __async(null, null, function* ()
|
|
|
516
516
|
return null;
|
|
517
517
|
}
|
|
518
518
|
const organization = results.entities[0];
|
|
519
|
-
return organization.organizationid;
|
|
519
|
+
return organization.organizationid.replace("{", "").replace("}", "").toLowerCase();
|
|
520
520
|
});
|
|
521
521
|
var IanusGuard = ({ publisherId, productId, publicKeys, environmentType, environmentIdentifier, dataProvider, offlineDataProvider, usagePermission, onLicenseValidated, children }) => {
|
|
522
522
|
var _a, _b, _c, _d, _e;
|
|
@@ -535,7 +535,7 @@ var IanusGuard = ({ publisherId, productId, publicKeys, environmentType, environ
|
|
|
535
535
|
const runValidation = React4.useCallback(() => __async(null, null, function* () {
|
|
536
536
|
try {
|
|
537
537
|
if (resolvedEnvironmentIdentifierRef.current === null) {
|
|
538
|
-
resolvedEnvironmentIdentifierRef.current = isWebApi(environmentIdentifier) ? yield fetchOrganizationIdFromWebApi(environmentIdentifier) : environmentIdentifier;
|
|
538
|
+
resolvedEnvironmentIdentifierRef.current = isWebApi(environmentIdentifier) ? yield fetchOrganizationIdFromWebApi(environmentIdentifier) : environmentIdentifier == null ? void 0 : environmentIdentifier.replace("{", "").replace("}", "").toLowerCase();
|
|
539
539
|
}
|
|
540
540
|
if (!resolvedEnvironmentIdentifierRef.current) {
|
|
541
541
|
return {
|
|
@@ -641,12 +641,44 @@ var IanusGuard = ({ publisherId, productId, publicKeys, environmentType, environ
|
|
|
641
641
|
}
|
|
642
642
|
return "";
|
|
643
643
|
}, [offlineDataProvider]);
|
|
644
|
+
const prevDeps = React4.useRef({
|
|
645
|
+
dataProvider,
|
|
646
|
+
dataProviderState,
|
|
647
|
+
dataProviderSignature,
|
|
648
|
+
initLicenseValidation,
|
|
649
|
+
licenseDispatch,
|
|
650
|
+
usagePermission,
|
|
651
|
+
offlineDataProvider,
|
|
652
|
+
offlineDataProviderState,
|
|
653
|
+
offlineDataProviderSignature
|
|
654
|
+
});
|
|
644
655
|
React4.useEffect(() => {
|
|
645
656
|
console.log(`Starting license evaluation at ${(/* @__PURE__ */ new Date()).toISOString()}`);
|
|
646
657
|
console.log(`DataProvider state: ${dataProviderState}`);
|
|
647
658
|
console.log(`DataProvider signature: ${dataProviderSignature}`);
|
|
648
659
|
console.log(`Offline DataProvider state: ${offlineDataProviderState}`);
|
|
649
660
|
console.log(`Offline DataProvider signature: ${offlineDataProviderSignature}`);
|
|
661
|
+
const prev = prevDeps.current;
|
|
662
|
+
if (prev.dataProvider !== dataProvider) console.log("dataProvider changed");
|
|
663
|
+
if (prev.dataProviderState !== dataProviderState) console.log("dataProviderState changed");
|
|
664
|
+
if (prev.dataProviderSignature !== dataProviderSignature) console.log("dataProviderSignature changed");
|
|
665
|
+
if (prev.initLicenseValidation !== initLicenseValidation) console.log("initLicenseValidation changed");
|
|
666
|
+
if (prev.licenseDispatch !== licenseDispatch) console.log("licenseDispatch changed");
|
|
667
|
+
if (prev.usagePermission !== usagePermission) console.log("usagePermission changed");
|
|
668
|
+
if (prev.offlineDataProvider !== offlineDataProvider) console.log("offlineDataProvider changed");
|
|
669
|
+
if (prev.offlineDataProviderState !== offlineDataProviderState) console.log("offlineDataProviderState changed");
|
|
670
|
+
if (prev.offlineDataProviderSignature !== offlineDataProviderSignature) console.log("offlineDataProviderSignature changed");
|
|
671
|
+
prevDeps.current = {
|
|
672
|
+
dataProvider,
|
|
673
|
+
dataProviderState,
|
|
674
|
+
dataProviderSignature,
|
|
675
|
+
initLicenseValidation,
|
|
676
|
+
licenseDispatch,
|
|
677
|
+
usagePermission,
|
|
678
|
+
offlineDataProvider,
|
|
679
|
+
offlineDataProviderState,
|
|
680
|
+
offlineDataProviderSignature
|
|
681
|
+
};
|
|
650
682
|
if (usagePermission != null && !usagePermission) {
|
|
651
683
|
const result = {
|
|
652
684
|
isValid: false,
|
package/package.json
CHANGED