express - node.js module require() twice -- (relative path) -


why qrchannelservice module required twice(mongoose throw overwritemethod error), why didn't cached ?

qrchannelservice path: mit/src/modules/qrchannel/services/qrchannelservice.js

require

path1: mit/src/controllers/api/qr.js var qrcodeservice = require('../../modules/qrchannel/services/qrchannelservice');


path2: mit/src/modules/qrchannel/common/qrhandlerdispather.js var qrchannelservice = require('../services/qrchannelservice');


Comments

Popular posts from this blog

android - Gradle sync Error:Configuration with name 'default' not found -

java - Andrioid studio start fail: Fatal error initializing 'null' -

html - jQuery UI Sortable - Remove placeholder after item is dropped -