|
|
@ -13,16 +13,15 @@ console.log(`Plugin ${PLUGIN_NAME} is loaded`);
|
|
|
|
setTimeout(() => {
|
|
|
|
setTimeout(() => {
|
|
|
|
console.log('Report plugin install status');
|
|
|
|
console.log('Report plugin install status');
|
|
|
|
|
|
|
|
|
|
|
|
const storage = JSON.parse(window.localStorage['$TailchatInstalledPlugins']);
|
|
|
|
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
|
|
|
|
const storage = JSON.parse(
|
|
|
|
|
|
|
|
window.localStorage['$TailchatInstalledPlugins']
|
|
|
|
|
|
|
|
);
|
|
|
|
posthog.capture('Report Plugin', {
|
|
|
|
posthog.capture('Report Plugin', {
|
|
|
|
plugins: storage.rawData,
|
|
|
|
plugins: storage.rawData,
|
|
|
|
pluginNum: Array.isArray(storage.rawData) ? storage.rawData.length : 0,
|
|
|
|
pluginNum: Array.isArray(storage.rawData) ? storage.rawData.length : 0,
|
|
|
|
});
|
|
|
|
});
|
|
|
|
} catch (err) {
|
|
|
|
} catch (err) {
|
|
|
|
posthog.capture('Report Plugin error', {
|
|
|
|
// Ignore error
|
|
|
|
err: String(err),
|
|
|
|
|
|
|
|
storage,
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}, 2000);
|
|
|
|
}, 2000);
|
|
|
|