Extension: Port to ESM
This commit is contained in:
+4
-8
@@ -1,16 +1,12 @@
|
||||
// SPDX-FileCopyrightText: 2022 Romain Vigier <contact AT romainvigier.fr>
|
||||
// SPDX-License-Identifier: GPL-3.0-or-later
|
||||
|
||||
const { extensionUtils } = imports.misc;
|
||||
|
||||
const Me = extensionUtils.getCurrentExtension();
|
||||
|
||||
/**
|
||||
* Print a message in debug builds.
|
||||
*
|
||||
* @param {string} msg Message to print.
|
||||
* @param {string} msg Message to print.
|
||||
*/
|
||||
function message(msg) {
|
||||
if (Me.metadata['build-type'] === 'debug')
|
||||
console.log(`[${Me.metadata.name}] ${msg}`);
|
||||
export function message(msg) {
|
||||
if (NTSMetadata['build-type'] === 'debug')
|
||||
console.log(`[${NTSMetadata.name}] ${msg}`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user