Show console.log 'Legacy attachments route loaded' only when environment variable DEBUG=true.

Thanks to xet7 !
This commit is contained in:
Lauri Ojansivu 2025-10-10 21:19:00 +03:00
parent 2c73dae019
commit 1c84b19f24

View file

@ -4,7 +4,9 @@ import { ReactiveCache } from '/imports/reactiveCache';
import { getAttachmentWithBackwardCompatibility, getOldAttachmentStream } from '/models/lib/attachmentBackwardCompatibility';
// Ensure this file is loaded
console.log('Legacy attachments route loaded');
if (process.env.DEBUG === 'true') {
console.log('Legacy attachments route loaded');
}
/**
* Legacy attachment download route for CollectionFS compatibility