var ObjectId = require('mongodb').ObjectId;
var Hashids = require("hashids");
var moment = require("moment");

module.exports = function (context) {

    var salt = context ? context : new ObjectId().toString();

    var hashids = new Hashids(salt, 8, "ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890");
    var now = moment();
    var begin = now.clone().startOf("month");
    var diff = now.diff(begin);
    var code = `${hashids.encode(diff)}`;
    // return salt;
    return code;
};
@@ -260,17 +260,16 @@
 GHIJKLMN
-O
 PQRSTUVW
@@ -284,9 +284,8 @@
 6789
-0
 %22);%0A

fix code generator