Skip to content

Commit

Permalink
chore: updated debug messages
Browse files Browse the repository at this point in the history
  • Loading branch information
cnouguier committed Oct 8, 2024
1 parent 4301270 commit f8ffade
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion core/client/capabilities.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ export const Capabilities = {
async initialize () {
const capabilities = await window.fetch(api.getConfig('domain') + _.get(config, 'apiPath') + '/capabilities')
const content = await capabilities.json()
logger.debug('[KDK] Fetched capabilities:', JSON.stringify(content, null, 4))
logger.debug('[KDK] Fetched capabilities:', content)
this.content = content
// Backend might override some defaults in client config
_.forOwn(_.pick(content, ['gateway']), (value, key) => {
Expand Down
2 changes: 1 addition & 1 deletion core/client/document.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export const Document = {
},
mdConverter: {}
})
logger.debug('[KDK] Document options:', JSON.stringify(this.options, null, 4))
logger.debug('[KDK] Configuring documents with options:', this.options)
},
register (mimeTypes, viewer) {
if (!_.isArray(mimeTypes)) mimeTypes = [mimeTypes]
Expand Down
2 changes: 1 addition & 1 deletion core/client/exporter.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { i18n } from './i18n.js'
const ExporterQueue = {
initialize (maxConcurrentRequests) {
this.maxConcurrentRequests = maxConcurrentRequests
logger.debug(`[KDK] Exporter initialized with ${maxConcurrentRequests} maxConcurrentRequests`)
logger.debug(`[KDK] Configuring exporter with '${maxConcurrentRequests}' maxConcurrentRequests`)
this.pendingRequests = []
this.runningRequests = []
this.exportService = api.getService('import-export')
Expand Down
2 changes: 1 addition & 1 deletion core/client/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ export * from '../common/index.js'
export default async function initialize () {
const api = this

logger.debug('[KDK] initializing core module')
logger.debug('[KDK] Initializing core module')

// Declare the module initialization states
Store.set('kdk', { core: { initialized: false }, map: { initialized: false } })
Expand Down
2 changes: 1 addition & 1 deletion core/client/layout.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ export const Layout = {
})
Store.set(this.paths.focus, this.getElementDefaults('focus'))
// debug message
logger.debug('[KDK] Layout set up with the following configuration:', this.get())
logger.debug('[KDK] Configuring layout with options:', this.get())
},
get () {
return Store.get(this.paths.layout)
Expand Down
2 changes: 1 addition & 1 deletion core/client/local-storage.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import config from 'config'
export const LocalStorage = {
initialize () {
this.prefix = _.kebabCase(_.get(config, 'appName', 'kdk'))
logger.debug(`[KDK] initializing local storage with prefix: '${this.prefix}'`)
logger.debug(`[KDK] Configuring local storage with prefix: '${this.prefix}'`)
},
localKey (key) {
const keyPrefix = `${this.prefix}-`
Expand Down
4 changes: 2 additions & 2 deletions map/client/init.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export function setupApi (configuration) {
export default async function init () {
const api = this

logger.debug('[KDK] initializing map module')
logger.debug('[KDK] Initializing map module')

// Declare the built-in services, others are optional
api.declareService('geocoder')
Expand Down Expand Up @@ -89,7 +89,7 @@ export default async function init () {

// Register the readers
_.forEach(_.get(config, 'readers.map', []), entry => {
logger.debug(`[KDK] registering mime types [${entry.mimeTypes}] to reader ${entry.reader}`)
logger.debug(`[KDK] Registering mime types [${entry.mimeTypes}] to reader ${entry.reader}`)
Reader.register(entry.mimeTypes, readers[entry.reader])
})

Expand Down
2 changes: 1 addition & 1 deletion map/client/mixins/mixin.activity.js
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ export const activity = {
// Merge the engine options using defaults
const defaultOptions = _.get(config, `engines.${this.engine}`)
if (defaultOptions) {
logger.debug(`[KDK] ${this.engine} engine use defaults: ${JSON.stringify(defaultOptions, null, 2)}`)
logger.debug(`[KDK] Configuring '${this.engine}' engine with options:`, defaultOptions)
// Take care that if we only use the default options the specific options will be undefined
this.activityOptions.engine = _.defaultsDeep(_.get(this.activityOptions, 'engine', {}), defaultOptions)
}
Expand Down

0 comments on commit f8ffade

Please sign in to comment.