Skip to content

Commit

Permalink
fix: Merge pull request #5 from pelias/use-isenabled-for-consistency
Browse files Browse the repository at this point in the history
use `isEnabled()` instead of checking `getBaseUrl()`
  • Loading branch information
trescube authored Jun 9, 2017
2 parents ae25807 + 88c4266 commit 69eb5e9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion service.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ module.exports = function setup(serviceConfig) {

const logger = require( 'pelias-logger' ).get( serviceConfig.getName() );

if (_.isEmpty(serviceConfig.getBaseUrl())) {
if (!serviceConfig.isEnabled()) {
logger.warn(`${serviceConfig.getName()} service disabled`);

return (req, callback) => {
Expand Down

0 comments on commit 69eb5e9

Please sign in to comment.