These rules are adopted from the AngularJS commit conventions.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
var _Campaign = require('../models/Campaign'); | |
const reEXCLUSIEF = new RegExp('^ww[w0-9^]\.'); // | |
// targets.retainTraffic.domain | |
const dirtyObjCursor = _Campaign.default.find({ 'targets.retainTraffic.domain': { $regex: reEXCLUSIEF } }).cursor(); | |
dirtyObjCursor.on('data', obj => { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Campaign = require('../models/Campaign'); | |
const re = new RegExp('( )?(\||\:|\-)?( |[(])?EXCLUSIEF(.*)'); | |
const d = Campaign.default.find({'offer.text':{$regex: re}}).cursor(); | |
d.on('data', o=>{ | |
console.log(o._id,o.offer.text); | |
Campaign.default.update({_id:o._id}, {$set:{'offer.text': o.title.replace(re,'').replace('|','').trim()}}).then(ee=>console.log(ee)); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
// Generated on 2014-04-14 using generator-leaflet 0.0.14 | |
var gulp = require('gulp'); | |
var open = require('open'); | |
var wiredep = require('wiredep').stream; | |
// Load plugins | |
var $ = require('gulp-load-plugins')(); |