Switch to xxhash to save farmhash jiggery-pokery when initialising Docker image

This commit is contained in:
David Stephens 2017-11-26 18:26:56 +00:00
parent b25b96d9de
commit 10044b6749
2 changed files with 3 additions and 3 deletions

View file

@ -14,7 +14,7 @@ const paths = require('path');
const assert = require('assert');
const iconv = require('iconv-lite');
const _ = require('lodash');
const farmhash = require('farmhash');
const xxhash = require('xxhash');
exports.getArt = getArt;
exports.getArtFromPath = getArtFromPath;
@ -288,7 +288,7 @@ function display(client, art, options, cb) {
}
if(!options.disableMciCache) {
artHash = farmhash.hash32(art);
artHash = xxhash.hash(new Buffer(art), 0xCAFEBABE);
// see if we have a mciMap cached for this art
if(client.mciCache) {