mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-06 01:47:48 +00:00
Update vendors.
Former-commit-id: a2830d4097d13884391abe792c319bf1e699df08
This commit is contained in:
27
vendor/curl/src/curl.js
vendored
27
vendor/curl/src/curl.js
vendored
@@ -13,7 +13,7 @@
|
||||
(function (global) {
|
||||
//"use strict"; don't restore this until the config routine is refactored
|
||||
var
|
||||
version = '0.7.4',
|
||||
version = '0.7.6',
|
||||
curlName = 'curl',
|
||||
defineName = 'define',
|
||||
runModuleAttr = 'data-curl-run',
|
||||
@@ -303,15 +303,32 @@
|
||||
|
||||
// functions that dependencies will use:
|
||||
|
||||
function toAbsId (childId) {
|
||||
return core.toAbsId(childId, def.id, cfg);
|
||||
function toAbsId (childId, checkPlugins) {
|
||||
var absId, parts, plugin;
|
||||
|
||||
absId = core.toAbsId(childId, def.id, cfg);
|
||||
if (!checkPlugins) return absId;
|
||||
|
||||
parts = pluginParts(absId);
|
||||
if (!parts.pluginId) return absId;
|
||||
|
||||
plugin = cache[parts.pluginId];
|
||||
// check if plugin supports the normalize method
|
||||
if ('normalize' in plugin) {
|
||||
// note: dojo/has may return falsey values (0, actually)
|
||||
parts.resourceId = plugin['normalize'](parts.resourceId, toAbsId, def.config) || '';
|
||||
}
|
||||
else {
|
||||
parts.resourceId = toAbsId(parts.resourceId);
|
||||
}
|
||||
return parts.pluginId + '!' + parts.resourceId;
|
||||
}
|
||||
|
||||
function toUrl (n) {
|
||||
// the AMD spec states that we should not append an extension
|
||||
// in this function since it could already be appended.
|
||||
// we need to use toAbsId in case this is a module id.
|
||||
return core.resolvePathInfo(toAbsId(n), cfg).url;
|
||||
return core.resolvePathInfo(toAbsId(n, true), cfg).url;
|
||||
}
|
||||
|
||||
function localRequire (ids, callback, errback) {
|
||||
@@ -327,7 +344,7 @@
|
||||
throw new Error('require(id, callback) not allowed');
|
||||
}
|
||||
// return resource
|
||||
rvid = toAbsId(ids);
|
||||
rvid = toAbsId(ids, true);
|
||||
childDef = cache[rvid];
|
||||
if (!(rvid in cache)) {
|
||||
// this should only happen when devs attempt their own
|
||||
|
||||
Reference in New Issue
Block a user