asdf-games/node_modules/plur/index.js

10 lines
181 B
JavaScript
Raw Normal View History

'use strict';
module.exports = function (str, plural, count) {
if (typeof plural === 'number') {
count = plural;
plural = str + 's';
}
return count === 1 ? str : plural;
};