From aa79df03c72e98a284bf9250b59c4fba8cb8e2a8 Mon Sep 17 00:00:00 2001 From: SamTV12345 <40429738+samtv12345@users.noreply.github.com> Date: Mon, 25 May 2026 16:45:35 +0200 Subject: [PATCH] fix: backward-compat for ESM etherpad - Migrate log4js to ep_plugin_helpers/logger Backward-compatible with current CJS etherpad release; also compatible with the upcoming ESM etherpad branch which has stricter exports map resolution. --- index.js | 4 ++-- package.json | 5 ++++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/index.js b/index.js index 31495fc..fb588ac 100644 --- a/index.js +++ b/index.js @@ -1,9 +1,9 @@ 'use strict'; const assert = require('assert').strict; -const log4js = require('ep_etherpad-lite/node_modules/log4js'); +const {createLogger} = require('ep_plugin_helpers/logger'); -const logger = log4js.getLogger('ep_disable_imports'); +const logger = createLogger('ep_disable_imports'); let allow = new Set(); let deny = new Set(); diff --git a/package.json b/package.json index df31969..dab66f5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ep_disable_imports", - "version": "1.0.49", + "version": "1.0.50", "description": "Etherpad plugin to selectively or completely disable imports.", "main": "index.js", "scripts": { @@ -33,5 +33,8 @@ "funding": { "type": "individual", "url": "https://etherpad.org/" + }, + "dependencies": { + "ep_plugin_helpers": "^0.6.7" } }