随机图片接口优化

This commit is contained in:
tangly1024.com
2023-08-08 15:22:58 +08:00
parent 2749b73e08
commit 23e23a8a8e
2 changed files with 10 additions and 2 deletions

View File

@@ -57,7 +57,7 @@ const handleAckee = async function(pathname, environment, options = {}) {
await loadExternalResource(BLOG.ANALYTICS_ACKEE_TRACKER, 'js')
const ackeeTracker = window.ackeeTracker
const instance = ackeeTracker.create(environment.server, options)
const instance = ackeeTracker?.create(environment.server, options)
if (instance == null) {
console.warn('Skipped record creation because useAckee has been called in a non-browser environment')
@@ -73,7 +73,7 @@ const handleAckee = async function(pathname, environment, options = {}) {
return
}
const attributes = ackeeTracker.attributes(options.detailed)
const attributes = ackeeTracker?.attributes(options.detailed)
const url = new URL(pathname, location)
return instance.record(environment.domainId, {