]> git.ipfire.org Git - thirdparty/moment.git/commitdiff
Filter out en from locales
authorKunal Marwaha <marwahaha@berkeley.edu>
Sat, 18 Mar 2017 06:21:31 +0000 (02:21 -0400)
committerIskren Chernev <iskren.chernev@gmail.com>
Sat, 18 Mar 2017 19:35:04 +0000 (21:35 +0200)
tasks/transpile.js

index 5223bd85f13be144a27837dec6f0257d91da7d27..25011ed81c2e50fd64004fd01273b1263ce69c47 100644 (file)
@@ -280,7 +280,7 @@ module.exports = function (grunt) {
             grunt.log.ok('build/umd/min/moment-with-locales.custom.js');
         }).then(function () {
             var moment = require('../build/umd/min/moment-with-locales.custom.js');
-            if (moment.locales().length !== localeFiles.length) {
+            if (moment.locales().filter(locale => locale !== 'en').length !== localeFiles.length) {
                 throw new Error(
                     'You probably specified locales requiring ' +
                     'parent locale, but didn\'t specify parent');