controller: Only init submit notification if requested
* src/server/daemon/controller.js (exports.init): Do not initialize submit notifier if no URL was provided.master
parent
b32d4e3d1b
commit
ad52dbec9a
|
@ -146,9 +146,14 @@ exports.init = function( logger, enc_service, conf )
|
||||||
''
|
''
|
||||||
);
|
);
|
||||||
|
|
||||||
rating_service = RatingService
|
// only use the submit notification if a URL was provided
|
||||||
.use( RatingServiceSubmitNotify( createSubmitDapi, dao ) )
|
const RatingServiceBase = ( exports.no_results_url )
|
||||||
(
|
? RatingService.use(
|
||||||
|
RatingServiceSubmitNotify( createSubmitDapi, dao )
|
||||||
|
)
|
||||||
|
: RatingService;
|
||||||
|
|
||||||
|
rating_service = RatingServiceBase(
|
||||||
logger, dao, server, exports.rater
|
logger, dao, server, exports.rater
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue