Get off off rails-assets
Just moving the things we currently use (and should drop in the ASAP) to vendor/assets
This commit is contained in:
parent
9fd0807a9a
commit
b6560dbb34
659 changed files with 129299 additions and 67 deletions
20
vendor/assets/javascripts/momentjs/src/lib/create/from-object.js
vendored
Normal file
20
vendor/assets/javascripts/momentjs/src/lib/create/from-object.js
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
import { normalizeObjectUnits } from '../units/aliases';
|
||||
import { configFromArray } from './from-array';
|
||||
import map from '../utils/map';
|
||||
|
||||
export function configFromObject(config) {
|
||||
if (config._d) {
|
||||
return;
|
||||
}
|
||||
|
||||
var i = normalizeObjectUnits(config._i),
|
||||
dayOrDate = i.day === undefined ? i.date : i.day;
|
||||
config._a = map(
|
||||
[i.year, i.month, dayOrDate, i.hour, i.minute, i.second, i.millisecond],
|
||||
function (obj) {
|
||||
return obj && parseInt(obj, 10);
|
||||
}
|
||||
);
|
||||
|
||||
configFromArray(config);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue