diff --git a/dist/backlog.js b/dist/backlog.js index 39ee6dd..4349305 100644 --- a/dist/backlog.js +++ b/dist/backlog.js @@ -504,8 +504,15 @@ var Backlog = /** @class */ (function (_super) { }; /** * https://developer.nulab.com/docs/backlog/api/2/delete-issue/ + * @deprecated Renamed to `deleteIssue`. */ Backlog.prototype.deleteIssuesCount = function (issueIdOrKey) { + return this.deleteIssue(issueIdOrKey); + }; + /** + * https://developer.nulab.com/docs/backlog/api/2/delete-issue/ + */ + Backlog.prototype.deleteIssue = function (issueIdOrKey) { return this.delete("issues/".concat(issueIdOrKey)); }; /** diff --git a/dist/backlog.min.js b/dist/backlog.min.js index f86a346..e31a426 100644 --- a/dist/backlog.min.js +++ b/dist/backlog.min.js @@ -1 +1 @@ -(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Backlog=f()}})(function(){var define,module,exports;return function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i0}).join("&")};OAuth2.prototype.getAccessToken=function(options){return new request_1.default({host:options.host,timeout:this.timeout}).post("oauth2/token",{grant_type:"authorization_code",code:options.code,client_id:this.credentials.clientId,client_secret:this.credentials.clientSecret,redirect_uri:options.redirectUri})};OAuth2.prototype.refreshAccessToken=function(options){return new request_1.default({host:options.host,timeout:this.timeout}).post("oauth2/token",{grant_type:"refresh_token",client_id:this.credentials.clientId,client_secret:this.credentials.clientSecret,refresh_token:options.refreshToken})};return OAuth2}();exports.default=OAuth2},{"./request":7}],6:[function(require,module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.Issue=void 0;var Issue;(function(Issue){var ParentChildType;(function(ParentChildType){ParentChildType[ParentChildType["All"]=0]="All";ParentChildType[ParentChildType["NotChild"]=1]="NotChild";ParentChildType[ParentChildType["Child"]=2]="Child";ParentChildType[ParentChildType["NotChildNotParent"]=3]="NotChildNotParent";ParentChildType[ParentChildType["Parent"]=4]="Parent"})(ParentChildType=Issue.ParentChildType||(Issue.ParentChildType={}))})(Issue||(exports.Issue=Issue={}))},{}],7:[function(require,module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var Error=require("./error");var qs=require("qs");var Request=function(){function Request(configure){this.configure=configure}Request.prototype.get=function(path,params){return this.request({method:"GET",path:path,params:params}).then(this.parseJSON)};Request.prototype.post=function(path,params){return this.request({method:"POST",path:path,params:params}).then(this.parseJSON)};Request.prototype.put=function(path,params){return this.request({method:"PUT",path:path,params:params}).then(this.parseJSON)};Request.prototype.patch=function(path,params){return this.request({method:"PATCH",path:path,params:params}).then(this.parseJSON)};Request.prototype.delete=function(path,params){return this.request({method:"DELETE",path:path,params:params}).then(this.parseJSON)};Request.prototype.request=function(options){var method=options.method,path=options.path,_a=options.params,params=_a===void 0?{}:_a;var _b=this.configure,apiKey=_b.apiKey,accessToken=_b.accessToken,timeout=_b.timeout;var query=apiKey?{apiKey:apiKey}:{};var init={method:method,headers:{}};if(timeout){init["timeout"]=timeout}if(!apiKey&&accessToken){init.headers["Authorization"]="Bearer "+accessToken}if(typeof window!=="undefined"){init.mode="cors"}if(method!=="GET"){if(params instanceof FormData){init.body=params}else{init.headers["Content-type"]="application/x-www-form-urlencoded";init.body=this.toQueryString(params)}}else{Object.keys(params).forEach(function(key){return query[key]=params[key]})}var queryStr=this.toQueryString(query);var url="".concat(this.restBaseURL,"/").concat(path)+(queryStr.length>0?"?".concat(queryStr):"");return fetch(url,init).then(this.checkStatus)};Request.prototype.checkStatus=function(response){return new Promise(function(resolve,reject){if(200<=response.status&&response.status<300){resolve(response)}else{response.json().then(function(data){if(response.status===401){reject(new Error.BacklogAuthError(response,data))}else{reject(new Error.BacklogApiError(response,data))}}).catch(function(err){return reject(new Error.UnexpectedError(response))})}})};Request.prototype.parseJSON=function(response){return response.json()};Request.prototype.toQueryString=function(params){return qs.stringify(params,{arrayFormat:"brackets"})};Object.defineProperty(Request.prototype,"webAppBaseURL",{get:function(){return"https://".concat(this.configure.host)},enumerable:false,configurable:true});Object.defineProperty(Request.prototype,"restBaseURL",{get:function(){return"".concat(this.webAppBaseURL,"/api/v2")},enumerable:false,configurable:true});return Request}();exports.default=Request},{"./error":3,qs:32}],8:[function(require,module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.CustomFieldType=exports.ActivityType=exports.NormalRoleType=exports.ClassicRoleType=void 0;var ClassicRoleType;(function(ClassicRoleType){ClassicRoleType[ClassicRoleType["Admin"]=1]="Admin";ClassicRoleType[ClassicRoleType["User"]=2]="User";ClassicRoleType[ClassicRoleType["Reporter"]=3]="Reporter";ClassicRoleType[ClassicRoleType["Viewer"]=4]="Viewer";ClassicRoleType[ClassicRoleType["GuestReporter"]=5]="GuestReporter";ClassicRoleType[ClassicRoleType["GuestViewer"]=6]="GuestViewer"})(ClassicRoleType||(exports.ClassicRoleType=ClassicRoleType={}));var NormalRoleType;(function(NormalRoleType){NormalRoleType[NormalRoleType["Admin"]=1]="Admin";NormalRoleType[NormalRoleType["MemberOrGuest"]=2]="MemberOrGuest";NormalRoleType[NormalRoleType["MemberOrGuestForAddIssues"]=3]="MemberOrGuestForAddIssues";NormalRoleType[NormalRoleType["MemberOrGuestForViewIssues"]=4]="MemberOrGuestForViewIssues"})(NormalRoleType||(exports.NormalRoleType=NormalRoleType={}));var ActivityType;(function(ActivityType){ActivityType[ActivityType["Undefined"]=-1]="Undefined";ActivityType[ActivityType["IssueCreated"]=1]="IssueCreated";ActivityType[ActivityType["IssueUpdated"]=2]="IssueUpdated";ActivityType[ActivityType["IssueCommented"]=3]="IssueCommented";ActivityType[ActivityType["IssueDeleted"]=4]="IssueDeleted";ActivityType[ActivityType["WikiCreated"]=5]="WikiCreated";ActivityType[ActivityType["WikiUpdated"]=6]="WikiUpdated";ActivityType[ActivityType["WikiDeleted"]=7]="WikiDeleted";ActivityType[ActivityType["FileAdded"]=8]="FileAdded";ActivityType[ActivityType["FileUpdated"]=9]="FileUpdated";ActivityType[ActivityType["FileDeleted"]=10]="FileDeleted";ActivityType[ActivityType["SvnCommitted"]=11]="SvnCommitted";ActivityType[ActivityType["GitPushed"]=12]="GitPushed";ActivityType[ActivityType["GitRepositoryCreated"]=13]="GitRepositoryCreated";ActivityType[ActivityType["IssueMultiUpdated"]=14]="IssueMultiUpdated";ActivityType[ActivityType["ProjectUserAdded"]=15]="ProjectUserAdded";ActivityType[ActivityType["ProjectUserRemoved"]=16]="ProjectUserRemoved";ActivityType[ActivityType["NotifyAdded"]=17]="NotifyAdded";ActivityType[ActivityType["PullRequestAdded"]=18]="PullRequestAdded";ActivityType[ActivityType["PullRequestUpdated"]=19]="PullRequestUpdated";ActivityType[ActivityType["PullRequestCommented"]=20]="PullRequestCommented";ActivityType[ActivityType["PullRequestMerged"]=21]="PullRequestMerged";ActivityType[ActivityType["MilestoneCreated"]=22]="MilestoneCreated";ActivityType[ActivityType["MilestoneUpdated"]=23]="MilestoneUpdated";ActivityType[ActivityType["MilestoneDeleted"]=24]="MilestoneDeleted";ActivityType[ActivityType["ProjectGroupAdded"]=25]="ProjectGroupAdded";ActivityType[ActivityType["ProjectGroupDeleted"]=26]="ProjectGroupDeleted"})(ActivityType||(exports.ActivityType=ActivityType={}));var CustomFieldType;(function(CustomFieldType){CustomFieldType[CustomFieldType["Text"]=1]="Text";CustomFieldType[CustomFieldType["TextArea"]=2]="TextArea";CustomFieldType[CustomFieldType["Numeric"]=3]="Numeric";CustomFieldType[CustomFieldType["Date"]=4]="Date";CustomFieldType[CustomFieldType["SingleList"]=5]="SingleList";CustomFieldType[CustomFieldType["MultipleList"]=6]="MultipleList";CustomFieldType[CustomFieldType["CheckBox"]=7]="CheckBox";CustomFieldType[CustomFieldType["Radio"]=8]="Radio"})(CustomFieldType||(exports.CustomFieldType=CustomFieldType={}))},{}],9:[function(require,module,exports){},{}],10:[function(require,module,exports){"use strict";var GetIntrinsic=require("get-intrinsic");var callBind=require("./");var $indexOf=callBind(GetIntrinsic("String.prototype.indexOf"));module.exports=function callBoundIntrinsic(name,allowMissing){var intrinsic=GetIntrinsic(name,!!allowMissing);if(typeof intrinsic==="function"&&$indexOf(name,".prototype.")>-1){return callBind(intrinsic)}return intrinsic}},{"./":11,"get-intrinsic":23}],11:[function(require,module,exports){"use strict";var bind=require("function-bind");var GetIntrinsic=require("get-intrinsic");var setFunctionLength=require("set-function-length");var $TypeError=require("es-errors/type");var $apply=GetIntrinsic("%Function.prototype.apply%");var $call=GetIntrinsic("%Function.prototype.call%");var $reflectApply=GetIntrinsic("%Reflect.apply%",true)||bind.call($call,$apply);var $defineProperty=require("es-define-property");var $max=GetIntrinsic("%Math.max%");module.exports=function callBind(originalFunction){if(typeof originalFunction!=="function"){throw new $TypeError("a function is required")}var func=$reflectApply(bind,$call,arguments);return setFunctionLength(func,1+$max(0,originalFunction.length-(arguments.length-1)),true)};var applyBind=function applyBind(){return $reflectApply(bind,$apply,arguments)};if($defineProperty){$defineProperty(module.exports,"apply",{value:applyBind})}else{module.exports.apply=applyBind}},{"es-define-property":13,"es-errors/type":19,"function-bind":22,"get-intrinsic":23,"set-function-length":36}],12:[function(require,module,exports){"use strict";var $defineProperty=require("es-define-property");var $SyntaxError=require("es-errors/syntax");var $TypeError=require("es-errors/type");var gopd=require("gopd");module.exports=function defineDataProperty(obj,property,value){if(!obj||typeof obj!=="object"&&typeof obj!=="function"){throw new $TypeError("`obj` must be an object or a function`")}if(typeof property!=="string"&&typeof property!=="symbol"){throw new $TypeError("`property` must be a string or a symbol`")}if(arguments.length>3&&typeof arguments[3]!=="boolean"&&arguments[3]!==null){throw new $TypeError("`nonEnumerable`, if provided, must be a boolean or null")}if(arguments.length>4&&typeof arguments[4]!=="boolean"&&arguments[4]!==null){throw new $TypeError("`nonWritable`, if provided, must be a boolean or null")}if(arguments.length>5&&typeof arguments[5]!=="boolean"&&arguments[5]!==null){throw new $TypeError("`nonConfigurable`, if provided, must be a boolean or null")}if(arguments.length>6&&typeof arguments[6]!=="boolean"){throw new $TypeError("`loose`, if provided, must be a boolean")}var nonEnumerable=arguments.length>3?arguments[3]:null;var nonWritable=arguments.length>4?arguments[4]:null;var nonConfigurable=arguments.length>5?arguments[5]:null;var loose=arguments.length>6?arguments[6]:false;var desc=!!gopd&&gopd(obj,property);if($defineProperty){$defineProperty(obj,property,{configurable:nonConfigurable===null&&desc?desc.configurable:!nonConfigurable,enumerable:nonEnumerable===null&&desc?desc.enumerable:!nonEnumerable,value:value,writable:nonWritable===null&&desc?desc.writable:!nonWritable})}else if(loose||!nonEnumerable&&!nonWritable&&!nonConfigurable){obj[property]=value}else{throw new $SyntaxError("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")}}},{"es-define-property":13,"es-errors/syntax":18,"es-errors/type":19,gopd:24}],13:[function(require,module,exports){"use strict";var GetIntrinsic=require("get-intrinsic");var $defineProperty=GetIntrinsic("%Object.defineProperty%",true)||false;if($defineProperty){try{$defineProperty({},"a",{value:1})}catch(e){$defineProperty=false}}module.exports=$defineProperty},{"get-intrinsic":23}],14:[function(require,module,exports){"use strict";module.exports=EvalError},{}],15:[function(require,module,exports){"use strict";module.exports=Error},{}],16:[function(require,module,exports){"use strict";module.exports=RangeError},{}],17:[function(require,module,exports){"use strict";module.exports=ReferenceError},{}],18:[function(require,module,exports){"use strict";module.exports=SyntaxError},{}],19:[function(require,module,exports){"use strict";module.exports=TypeError},{}],20:[function(require,module,exports){"use strict";module.exports=URIError},{}],21:[function(require,module,exports){"use strict";var ERROR_MESSAGE="Function.prototype.bind called on incompatible ";var toStr=Object.prototype.toString;var max=Math.max;var funcType="[object Function]";var concatty=function concatty(a,b){var arr=[];for(var i=0;i1&&typeof allowMissing!=="boolean"){throw new $TypeError('"allowMissing" argument must be a boolean')}if($exec(/^%?[^%]*%?$/,name)===null){throw new $SyntaxError("`%` may not be present anywhere but at the beginning and end of the intrinsic name")}var parts=stringToPath(name);var intrinsicBaseName=parts.length>0?parts[0]:"";var intrinsic=getBaseIntrinsic("%"+intrinsicBaseName+"%",allowMissing);var intrinsicRealName=intrinsic.name;var value=intrinsic.value;var skipFurtherCaching=false;var alias=intrinsic.alias;if(alias){intrinsicBaseName=alias[0];$spliceApply(parts,$concat([0,1],alias))}for(var i=1,isOwn=true;i=parts.length){var desc=$gOPD(value,part);isOwn=!!desc;if(isOwn&&"get"in desc&&!("originalValue"in desc.get)){value=desc.get}else{value=value[part]}}else{isOwn=hasOwn(value,part);value=value[part]}if(isOwn&&!skipFurtherCaching){INTRINSICS[intrinsicRealName]=value}}}return value}},{"es-errors":15,"es-errors/eval":14,"es-errors/range":16,"es-errors/ref":17,"es-errors/syntax":18,"es-errors/type":19,"es-errors/uri":20,"function-bind":22,"has-proto":26,"has-symbols":27,hasown:29}],24:[function(require,module,exports){"use strict";var GetIntrinsic=require("get-intrinsic");var $gOPD=GetIntrinsic("%Object.getOwnPropertyDescriptor%",true);if($gOPD){try{$gOPD([],"length")}catch(e){$gOPD=null}}module.exports=$gOPD},{"get-intrinsic":23}],25:[function(require,module,exports){"use strict";var $defineProperty=require("es-define-property");var hasPropertyDescriptors=function hasPropertyDescriptors(){return!!$defineProperty};hasPropertyDescriptors.hasArrayLengthDefineBug=function hasArrayLengthDefineBug(){if(!$defineProperty){return null}try{return $defineProperty([],"length",{value:1}).length!==1}catch(e){return true}};module.exports=hasPropertyDescriptors},{"es-define-property":13}],26:[function(require,module,exports){"use strict";var test={__proto__:null,foo:{}};var $Object=Object;module.exports=function hasProto(){return{__proto__:test}.foo===test.foo&&!(test instanceof $Object)}},{}],27:[function(require,module,exports){"use strict";var origSymbol=typeof Symbol!=="undefined"&&Symbol;var hasSymbolSham=require("./shams");module.exports=function hasNativeSymbols(){if(typeof origSymbol!=="function"){return false}if(typeof Symbol!=="function"){return false}if(typeof origSymbol("foo")!=="symbol"){return false}if(typeof Symbol("bar")!=="symbol"){return false}return hasSymbolSham()}},{"./shams":28}],28:[function(require,module,exports){"use strict";module.exports=function hasSymbols(){if(typeof Symbol!=="function"||typeof Object.getOwnPropertySymbols!=="function"){return false}if(typeof Symbol.iterator==="symbol"){return true}var obj={};var sym=Symbol("test");var symObj=Object(sym);if(typeof sym==="string"){return false}if(Object.prototype.toString.call(sym)!=="[object Symbol]"){return false}if(Object.prototype.toString.call(symObj)!=="[object Symbol]"){return false}var symVal=42;obj[sym]=symVal;for(sym in obj){return false}if(typeof Object.keys==="function"&&Object.keys(obj).length!==0){return false}if(typeof Object.getOwnPropertyNames==="function"&&Object.getOwnPropertyNames(obj).length!==0){return false}var syms=Object.getOwnPropertySymbols(obj);if(syms.length!==1||syms[0]!==sym){return false}if(!Object.prototype.propertyIsEnumerable.call(obj,sym)){return false}if(typeof Object.getOwnPropertyDescriptor==="function"){var descriptor=Object.getOwnPropertyDescriptor(obj,sym);if(descriptor.value!==symVal||descriptor.enumerable!==true){return false}}return true}},{}],29:[function(require,module,exports){"use strict";var call=Function.prototype.call;var $hasOwn=Object.prototype.hasOwnProperty;var bind=require("function-bind");module.exports=bind.call(call,$hasOwn)},{"function-bind":22}],30:[function(require,module,exports){(function(global){(function(){var hasMap=typeof Map==="function"&&Map.prototype;var mapSizeDescriptor=Object.getOwnPropertyDescriptor&&hasMap?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null;var mapSize=hasMap&&mapSizeDescriptor&&typeof mapSizeDescriptor.get==="function"?mapSizeDescriptor.get:null;var mapForEach=hasMap&&Map.prototype.forEach;var hasSet=typeof Set==="function"&&Set.prototype;var setSizeDescriptor=Object.getOwnPropertyDescriptor&&hasSet?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null;var setSize=hasSet&&setSizeDescriptor&&typeof setSizeDescriptor.get==="function"?setSizeDescriptor.get:null;var setForEach=hasSet&&Set.prototype.forEach;var hasWeakMap=typeof WeakMap==="function"&&WeakMap.prototype;var weakMapHas=hasWeakMap?WeakMap.prototype.has:null;var hasWeakSet=typeof WeakSet==="function"&&WeakSet.prototype;var weakSetHas=hasWeakSet?WeakSet.prototype.has:null;var hasWeakRef=typeof WeakRef==="function"&&WeakRef.prototype;var weakRefDeref=hasWeakRef?WeakRef.prototype.deref:null;var booleanValueOf=Boolean.prototype.valueOf;var objectToString=Object.prototype.toString;var functionToString=Function.prototype.toString;var $match=String.prototype.match;var $slice=String.prototype.slice;var $replace=String.prototype.replace;var $toUpperCase=String.prototype.toUpperCase;var $toLowerCase=String.prototype.toLowerCase;var $test=RegExp.prototype.test;var $concat=Array.prototype.concat;var $join=Array.prototype.join;var $arrSlice=Array.prototype.slice;var $floor=Math.floor;var bigIntValueOf=typeof BigInt==="function"?BigInt.prototype.valueOf:null;var gOPS=Object.getOwnPropertySymbols;var symToString=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?Symbol.prototype.toString:null;var hasShammedSymbols=typeof Symbol==="function"&&typeof Symbol.iterator==="object";var toStringTag=typeof Symbol==="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===hasShammedSymbols?"object":"symbol")?Symbol.toStringTag:null;var isEnumerable=Object.prototype.propertyIsEnumerable;var gPO=(typeof Reflect==="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(O){return O.__proto__}:null);function addNumericSeparator(num,str){if(num===Infinity||num===-Infinity||num!==num||num&&num>-1e3&&num<1e3||$test.call(/e/,str)){return str}var sepRegex=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof num==="number"){var int=num<0?-$floor(-num):$floor(num);if(int!==num){var intStr=String(int);var dec=$slice.call(str,intStr.length+1);return $replace.call(intStr,sepRegex,"$&_")+"."+$replace.call($replace.call(dec,/([0-9]{3})/g,"$&_"),/_$/,"")}}return $replace.call(str,sepRegex,"$&_")}var utilInspect=require("./util.inspect");var inspectCustom=utilInspect.custom;var inspectSymbol=isSymbol(inspectCustom)?inspectCustom:null;module.exports=function inspect_(obj,options,depth,seen){var opts=options||{};if(has(opts,"quoteStyle")&&(opts.quoteStyle!=="single"&&opts.quoteStyle!=="double")){throw new TypeError('option "quoteStyle" must be "single" or "double"')}if(has(opts,"maxStringLength")&&(typeof opts.maxStringLength==="number"?opts.maxStringLength<0&&opts.maxStringLength!==Infinity:opts.maxStringLength!==null)){throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`')}var customInspect=has(opts,"customInspect")?opts.customInspect:true;if(typeof customInspect!=="boolean"&&customInspect!=="symbol"){throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`")}if(has(opts,"indent")&&opts.indent!==null&&opts.indent!=="\t"&&!(parseInt(opts.indent,10)===opts.indent&&opts.indent>0)){throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`')}if(has(opts,"numericSeparator")&&typeof opts.numericSeparator!=="boolean"){throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`')}var numericSeparator=opts.numericSeparator;if(typeof obj==="undefined"){return"undefined"}if(obj===null){return"null"}if(typeof obj==="boolean"){return obj?"true":"false"}if(typeof obj==="string"){return inspectString(obj,opts)}if(typeof obj==="number"){if(obj===0){return Infinity/obj>0?"0":"-0"}var str=String(obj);return numericSeparator?addNumericSeparator(obj,str):str}if(typeof obj==="bigint"){var bigIntStr=String(obj)+"n";return numericSeparator?addNumericSeparator(obj,bigIntStr):bigIntStr}var maxDepth=typeof opts.depth==="undefined"?5:opts.depth;if(typeof depth==="undefined"){depth=0}if(depth>=maxDepth&&maxDepth>0&&typeof obj==="object"){return isArray(obj)?"[Array]":"[Object]"}var indent=getIndent(opts,depth);if(typeof seen==="undefined"){seen=[]}else if(indexOf(seen,obj)>=0){return"[Circular]"}function inspect(value,from,noIndent){if(from){seen=$arrSlice.call(seen);seen.push(from)}if(noIndent){var newOpts={depth:opts.depth};if(has(opts,"quoteStyle")){newOpts.quoteStyle=opts.quoteStyle}return inspect_(value,newOpts,depth+1,seen)}return inspect_(value,opts,depth+1,seen)}if(typeof obj==="function"&&!isRegExp(obj)){var name=nameOf(obj);var keys=arrObjKeys(obj,inspect);return"[Function"+(name?": "+name:" (anonymous)")+"]"+(keys.length>0?" { "+$join.call(keys,", ")+" }":"")}if(isSymbol(obj)){var symString=hasShammedSymbols?$replace.call(String(obj),/^(Symbol\(.*\))_[^)]*$/,"$1"):symToString.call(obj);return typeof obj==="object"&&!hasShammedSymbols?markBoxed(symString):symString}if(isElement(obj)){var s="<"+$toLowerCase.call(String(obj.nodeName));var attrs=obj.attributes||[];for(var i=0;i";return s}if(isArray(obj)){if(obj.length===0){return"[]"}var xs=arrObjKeys(obj,inspect);if(indent&&!singleLineValues(xs)){return"["+indentedJoin(xs,indent)+"]"}return"[ "+$join.call(xs,", ")+" ]"}if(isError(obj)){var parts=arrObjKeys(obj,inspect);if(!("cause"in Error.prototype)&&"cause"in obj&&!isEnumerable.call(obj,"cause")){return"{ ["+String(obj)+"] "+$join.call($concat.call("[cause]: "+inspect(obj.cause),parts),", ")+" }"}if(parts.length===0){return"["+String(obj)+"]"}return"{ ["+String(obj)+"] "+$join.call(parts,", ")+" }"}if(typeof obj==="object"&&customInspect){if(inspectSymbol&&typeof obj[inspectSymbol]==="function"&&utilInspect){return utilInspect(obj,{depth:maxDepth-depth})}else if(customInspect!=="symbol"&&typeof obj.inspect==="function"){return obj.inspect()}}if(isMap(obj)){var mapParts=[];if(mapForEach){mapForEach.call(obj,function(value,key){mapParts.push(inspect(key,obj,true)+" => "+inspect(value,obj))})}return collectionOf("Map",mapSize.call(obj),mapParts,indent)}if(isSet(obj)){var setParts=[];if(setForEach){setForEach.call(obj,function(value){setParts.push(inspect(value,obj))})}return collectionOf("Set",setSize.call(obj),setParts,indent)}if(isWeakMap(obj)){return weakCollectionOf("WeakMap")}if(isWeakSet(obj)){return weakCollectionOf("WeakSet")}if(isWeakRef(obj)){return weakCollectionOf("WeakRef")}if(isNumber(obj)){return markBoxed(inspect(Number(obj)))}if(isBigInt(obj)){return markBoxed(inspect(bigIntValueOf.call(obj)))}if(isBoolean(obj)){return markBoxed(booleanValueOf.call(obj))}if(isString(obj)){return markBoxed(inspect(String(obj)))}if(typeof window!=="undefined"&&obj===window){return"{ [object Window] }"}if(typeof globalThis!=="undefined"&&obj===globalThis||typeof global!=="undefined"&&obj===global){return"{ [object globalThis] }"}if(!isDate(obj)&&!isRegExp(obj)){var ys=arrObjKeys(obj,inspect);var isPlainObject=gPO?gPO(obj)===Object.prototype:obj instanceof Object||obj.constructor===Object;var protoTag=obj instanceof Object?"":"null prototype";var stringTag=!isPlainObject&&toStringTag&&Object(obj)===obj&&toStringTag in obj?$slice.call(toStr(obj),8,-1):protoTag?"Object":"";var constructorTag=isPlainObject||typeof obj.constructor!=="function"?"":obj.constructor.name?obj.constructor.name+" ":"";var tag=constructorTag+(stringTag||protoTag?"["+$join.call($concat.call([],stringTag||[],protoTag||[]),": ")+"] ":"");if(ys.length===0){return tag+"{}"}if(indent){return tag+"{"+indentedJoin(ys,indent)+"}"}return tag+"{ "+$join.call(ys,", ")+" }"}return String(obj)};function wrapQuotes(s,defaultStyle,opts){var quoteChar=(opts.quoteStyle||defaultStyle)==="double"?'"':"'";return quoteChar+s+quoteChar}function quote(s){return $replace.call(String(s),/"/g,""")}function isArray(obj){return toStr(obj)==="[object Array]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isDate(obj){return toStr(obj)==="[object Date]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isRegExp(obj){return toStr(obj)==="[object RegExp]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isError(obj){return toStr(obj)==="[object Error]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isString(obj){return toStr(obj)==="[object String]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isNumber(obj){return toStr(obj)==="[object Number]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isBoolean(obj){return toStr(obj)==="[object Boolean]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isSymbol(obj){if(hasShammedSymbols){return obj&&typeof obj==="object"&&obj instanceof Symbol}if(typeof obj==="symbol"){return true}if(!obj||typeof obj!=="object"||!symToString){return false}try{symToString.call(obj);return true}catch(e){}return false}function isBigInt(obj){if(!obj||typeof obj!=="object"||!bigIntValueOf){return false}try{bigIntValueOf.call(obj);return true}catch(e){}return false}var hasOwn=Object.prototype.hasOwnProperty||function(key){return key in this};function has(obj,key){return hasOwn.call(obj,key)}function toStr(obj){return objectToString.call(obj)}function nameOf(f){if(f.name){return f.name}var m=$match.call(functionToString.call(f),/^function\s*([\w$]+)/);if(m){return m[1]}return null}function indexOf(xs,x){if(xs.indexOf){return xs.indexOf(x)}for(var i=0,l=xs.length;iopts.maxStringLength){var remaining=str.length-opts.maxStringLength;var trailer="... "+remaining+" more character"+(remaining>1?"s":"");return inspectString($slice.call(str,0,opts.maxStringLength),opts)+trailer}var s=$replace.call($replace.call(str,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,lowbyte);return wrapQuotes(s,"single",opts)}function lowbyte(c){var n=c.charCodeAt(0);var x={8:"b",9:"t",10:"n",12:"f",13:"r"}[n];if(x){return"\\"+x}return"\\x"+(n<16?"0":"")+$toUpperCase.call(n.toString(16))}function markBoxed(str){return"Object("+str+")"}function weakCollectionOf(type){return type+" { ? }"}function collectionOf(type,size,entries,indent){var joinedEntries=indent?indentedJoin(entries,indent):$join.call(entries,", ");return type+" ("+size+") {"+joinedEntries+"}"}function singleLineValues(xs){for(var i=0;i=0){return false}}return true}function getIndent(opts,depth){var baseIndent;if(opts.indent==="\t"){baseIndent="\t"}else if(typeof opts.indent==="number"&&opts.indent>0){baseIndent=$join.call(Array(opts.indent+1)," ")}else{return null}return{base:baseIndent,prev:$join.call(Array(depth+1),baseIndent)}}function indentedJoin(xs,indent){if(xs.length===0){return""}var lineJoiner="\n"+indent.prev+indent.base;return lineJoiner+$join.call(xs,","+lineJoiner)+"\n"+indent.prev}function arrObjKeys(obj,inspect){var isArr=isArray(obj);var xs=[];if(isArr){xs.length=obj.length;for(var i=0;i-1){return val.split(",")}return val};var isoSentinel="utf8=%26%2310003%3B";var charsetSentinel="utf8=%E2%9C%93";var parseValues=function parseQueryStringValues(str,options){var obj={__proto__:null};var cleanStr=options.ignoreQueryPrefix?str.replace(/^\?/,""):str;var limit=options.parameterLimit===Infinity?undefined:options.parameterLimit;var parts=cleanStr.split(options.delimiter,limit);var skipIndex=-1;var i;var charset=options.charset;if(options.charsetSentinel){for(i=0;i-1){val=isArray(val)?[val]:val}var existing=has.call(obj,key);if(existing&&options.duplicates==="combine"){obj[key]=utils.combine(obj[key],val)}else if(!existing||options.duplicates==="last"){obj[key]=val}}return obj};var parseObject=function(chain,val,options,valuesParsed){var leaf=valuesParsed?val:parseArrayValue(val,options);for(var i=chain.length-1;i>=0;--i){var obj;var root=chain[i];if(root==="[]"&&options.parseArrays){obj=options.allowEmptyArrays&&leaf===""?[]:[].concat(leaf)}else{obj=options.plainObjects?Object.create(null):{};var cleanRoot=root.charAt(0)==="["&&root.charAt(root.length-1)==="]"?root.slice(1,-1):root;var decodedRoot=options.decodeDotInKeys?cleanRoot.replace(/%2E/g,"."):cleanRoot;var index=parseInt(decodedRoot,10);if(!options.parseArrays&&decodedRoot===""){obj={0:leaf}}else if(!isNaN(index)&&root!==decodedRoot&&String(index)===decodedRoot&&index>=0&&(options.parseArrays&&index<=options.arrayLimit)){obj=[];obj[index]=leaf}else if(decodedRoot!=="__proto__"){obj[decodedRoot]=leaf}}leaf=obj}return leaf};var parseKeys=function parseQueryStringKeys(givenKey,val,options,valuesParsed){if(!givenKey){return}var key=options.allowDots?givenKey.replace(/\.([^.[]+)/g,"[$1]"):givenKey;var brackets=/(\[[^[\]]*])/;var child=/(\[[^[\]]*])/g;var segment=options.depth>0&&brackets.exec(key);var parent=segment?key.slice(0,segment.index):key;var keys=[];if(parent){if(!options.plainObjects&&has.call(Object.prototype,parent)){if(!options.allowPrototypes){return}}keys.push(parent)}var i=0;while(options.depth>0&&(segment=child.exec(key))!==null&&i0?obj.join(",")||null:void undefined}]}else if(isArray(filter)){objKeys=filter}else{var keys=Object.keys(obj);objKeys=sort?keys.sort(sort):keys}var encodedPrefix=encodeDotInKeys?prefix.replace(/\./g,"%2E"):prefix;var adjustedPrefix=commaRoundTrip&&isArray(obj)&&obj.length===1?encodedPrefix+"[]":encodedPrefix;if(allowEmptyArrays&&isArray(obj)&&obj.length===0){return adjustedPrefix+"[]"}for(var j=0;j0?prefix+joined:""}},{"./formats":31,"./utils":35,"side-channel":37}],35:[function(require,module,exports){"use strict";var formats=require("./formats");var has=Object.prototype.hasOwnProperty;var isArray=Array.isArray;var hexTable=function(){var array=[];for(var i=0;i<256;++i){array.push("%"+((i<16?"0":"")+i.toString(16)).toUpperCase())}return array}();var compactQueue=function compactQueue(queue){while(queue.length>1){var item=queue.pop();var obj=item.obj[item.prop];if(isArray(obj)){var compacted=[];for(var j=0;j=limit?string.slice(j,j+limit):string;var arr=[];for(var i=0;i=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122||format===formats.RFC1738&&(c===40||c===41)){arr[arr.length]=segment.charAt(i);continue}if(c<128){arr[arr.length]=hexTable[c];continue}if(c<2048){arr[arr.length]=hexTable[192|c>>6]+hexTable[128|c&63];continue}if(c<55296||c>=57344){arr[arr.length]=hexTable[224|c>>12]+hexTable[128|c>>6&63]+hexTable[128|c&63];continue}i+=1;c=65536+((c&1023)<<10|segment.charCodeAt(i)&1023);arr[arr.length]=hexTable[240|c>>18]+hexTable[128|c>>12&63]+hexTable[128|c>>6&63]+hexTable[128|c&63]}out+=arr.join("")}return out};var compact=function compact(value){var queue=[{obj:{o:value},prop:"o"}];var refs=[];for(var i=0;i4294967295||$floor(length)!==length){throw new $TypeError("`length` must be a positive 32-bit integer")}var loose=arguments.length>2&&!!arguments[2];var functionLengthIsConfigurable=true;var functionLengthIsWritable=true;if("length"in fn&&gOPD){var desc=gOPD(fn,"length");if(desc&&!desc.configurable){functionLengthIsConfigurable=false}if(desc&&!desc.writable){functionLengthIsWritable=false}}if(functionLengthIsConfigurable||functionLengthIsWritable||!loose){if(hasDescriptors){define(fn,"length",length,true,true)}else{define(fn,"length",length)}}return fn}},{"define-data-property":12,"es-errors/type":19,"get-intrinsic":23,gopd:24,"has-property-descriptors":25}],37:[function(require,module,exports){"use strict";var GetIntrinsic=require("get-intrinsic");var callBound=require("call-bind/callBound");var inspect=require("object-inspect");var $TypeError=require("es-errors/type");var $WeakMap=GetIntrinsic("%WeakMap%",true);var $Map=GetIntrinsic("%Map%",true);var $weakMapGet=callBound("WeakMap.prototype.get",true);var $weakMapSet=callBound("WeakMap.prototype.set",true);var $weakMapHas=callBound("WeakMap.prototype.has",true);var $mapGet=callBound("Map.prototype.get",true);var $mapSet=callBound("Map.prototype.set",true);var $mapHas=callBound("Map.prototype.has",true);var listGetNode=function(list,key){var prev=list;var curr;for(;(curr=prev.next)!==null;prev=curr){if(curr.key===key){prev.next=curr.next;curr.next=list.next;list.next=curr;return curr}}};var listGet=function(objects,key){var node=listGetNode(objects,key);return node&&node.value};var listSet=function(objects,key,value){var node=listGetNode(objects,key);if(node){node.value=value}else{objects.next={key:key,next:objects.next,value:value}}};var listHas=function(objects,key){return!!listGetNode(objects,key)};module.exports=function getSideChannel(){var $wm;var $m;var $o;var channel={assert:function(key){if(!channel.has(key)){throw new $TypeError("Side channel does not contain "+inspect(key))}},get:function(key){if($WeakMap&&key&&(typeof key==="object"||typeof key==="function")){if($wm){return $weakMapGet($wm,key)}}else if($Map){if($m){return $mapGet($m,key)}}else{if($o){return listGet($o,key)}}},has:function(key){if($WeakMap&&key&&(typeof key==="object"||typeof key==="function")){if($wm){return $weakMapHas($wm,key)}}else if($Map){if($m){return $mapHas($m,key)}}else{if($o){return listHas($o,key)}}return false},set:function(key,value){if($WeakMap&&key&&(typeof key==="object"||typeof key==="function")){if(!$wm){$wm=new $WeakMap}$weakMapSet($wm,key,value)}else if($Map){if(!$m){$m=new $Map}$mapSet($m,key,value)}else{if(!$o){$o={key:{},next:null}}listSet($o,key,value)}}};return channel}},{"call-bind/callBound":10,"es-errors/type":19,"get-intrinsic":23,"object-inspect":30}]},{},[4])(4)}); \ No newline at end of file +(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.Backlog=f()}})(function(){var define,module,exports;return function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i0}).join("&")};OAuth2.prototype.getAccessToken=function(options){return new request_1.default({host:options.host,timeout:this.timeout}).post("oauth2/token",{grant_type:"authorization_code",code:options.code,client_id:this.credentials.clientId,client_secret:this.credentials.clientSecret,redirect_uri:options.redirectUri})};OAuth2.prototype.refreshAccessToken=function(options){return new request_1.default({host:options.host,timeout:this.timeout}).post("oauth2/token",{grant_type:"refresh_token",client_id:this.credentials.clientId,client_secret:this.credentials.clientSecret,refresh_token:options.refreshToken})};return OAuth2}();exports.default=OAuth2},{"./request":7}],6:[function(require,module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.Issue=void 0;var Issue;(function(Issue){var ParentChildType;(function(ParentChildType){ParentChildType[ParentChildType["All"]=0]="All";ParentChildType[ParentChildType["NotChild"]=1]="NotChild";ParentChildType[ParentChildType["Child"]=2]="Child";ParentChildType[ParentChildType["NotChildNotParent"]=3]="NotChildNotParent";ParentChildType[ParentChildType["Parent"]=4]="Parent"})(ParentChildType=Issue.ParentChildType||(Issue.ParentChildType={}))})(Issue||(exports.Issue=Issue={}))},{}],7:[function(require,module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var Error=require("./error");var qs=require("qs");var Request=function(){function Request(configure){this.configure=configure}Request.prototype.get=function(path,params){return this.request({method:"GET",path:path,params:params}).then(this.parseJSON)};Request.prototype.post=function(path,params){return this.request({method:"POST",path:path,params:params}).then(this.parseJSON)};Request.prototype.put=function(path,params){return this.request({method:"PUT",path:path,params:params}).then(this.parseJSON)};Request.prototype.patch=function(path,params){return this.request({method:"PATCH",path:path,params:params}).then(this.parseJSON)};Request.prototype.delete=function(path,params){return this.request({method:"DELETE",path:path,params:params}).then(this.parseJSON)};Request.prototype.request=function(options){var method=options.method,path=options.path,_a=options.params,params=_a===void 0?{}:_a;var _b=this.configure,apiKey=_b.apiKey,accessToken=_b.accessToken,timeout=_b.timeout;var query=apiKey?{apiKey:apiKey}:{};var init={method:method,headers:{}};if(timeout){init["timeout"]=timeout}if(!apiKey&&accessToken){init.headers["Authorization"]="Bearer "+accessToken}if(typeof window!=="undefined"){init.mode="cors"}if(method!=="GET"){if(params instanceof FormData){init.body=params}else{init.headers["Content-type"]="application/x-www-form-urlencoded";init.body=this.toQueryString(params)}}else{Object.keys(params).forEach(function(key){return query[key]=params[key]})}var queryStr=this.toQueryString(query);var url="".concat(this.restBaseURL,"/").concat(path)+(queryStr.length>0?"?".concat(queryStr):"");return fetch(url,init).then(this.checkStatus)};Request.prototype.checkStatus=function(response){return new Promise(function(resolve,reject){if(200<=response.status&&response.status<300){resolve(response)}else{response.json().then(function(data){if(response.status===401){reject(new Error.BacklogAuthError(response,data))}else{reject(new Error.BacklogApiError(response,data))}}).catch(function(err){return reject(new Error.UnexpectedError(response))})}})};Request.prototype.parseJSON=function(response){return response.json()};Request.prototype.toQueryString=function(params){return qs.stringify(params,{arrayFormat:"brackets"})};Object.defineProperty(Request.prototype,"webAppBaseURL",{get:function(){return"https://".concat(this.configure.host)},enumerable:false,configurable:true});Object.defineProperty(Request.prototype,"restBaseURL",{get:function(){return"".concat(this.webAppBaseURL,"/api/v2")},enumerable:false,configurable:true});return Request}();exports.default=Request},{"./error":3,qs:32}],8:[function(require,module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.CustomFieldType=exports.ActivityType=exports.NormalRoleType=exports.ClassicRoleType=void 0;var ClassicRoleType;(function(ClassicRoleType){ClassicRoleType[ClassicRoleType["Admin"]=1]="Admin";ClassicRoleType[ClassicRoleType["User"]=2]="User";ClassicRoleType[ClassicRoleType["Reporter"]=3]="Reporter";ClassicRoleType[ClassicRoleType["Viewer"]=4]="Viewer";ClassicRoleType[ClassicRoleType["GuestReporter"]=5]="GuestReporter";ClassicRoleType[ClassicRoleType["GuestViewer"]=6]="GuestViewer"})(ClassicRoleType||(exports.ClassicRoleType=ClassicRoleType={}));var NormalRoleType;(function(NormalRoleType){NormalRoleType[NormalRoleType["Admin"]=1]="Admin";NormalRoleType[NormalRoleType["MemberOrGuest"]=2]="MemberOrGuest";NormalRoleType[NormalRoleType["MemberOrGuestForAddIssues"]=3]="MemberOrGuestForAddIssues";NormalRoleType[NormalRoleType["MemberOrGuestForViewIssues"]=4]="MemberOrGuestForViewIssues"})(NormalRoleType||(exports.NormalRoleType=NormalRoleType={}));var ActivityType;(function(ActivityType){ActivityType[ActivityType["Undefined"]=-1]="Undefined";ActivityType[ActivityType["IssueCreated"]=1]="IssueCreated";ActivityType[ActivityType["IssueUpdated"]=2]="IssueUpdated";ActivityType[ActivityType["IssueCommented"]=3]="IssueCommented";ActivityType[ActivityType["IssueDeleted"]=4]="IssueDeleted";ActivityType[ActivityType["WikiCreated"]=5]="WikiCreated";ActivityType[ActivityType["WikiUpdated"]=6]="WikiUpdated";ActivityType[ActivityType["WikiDeleted"]=7]="WikiDeleted";ActivityType[ActivityType["FileAdded"]=8]="FileAdded";ActivityType[ActivityType["FileUpdated"]=9]="FileUpdated";ActivityType[ActivityType["FileDeleted"]=10]="FileDeleted";ActivityType[ActivityType["SvnCommitted"]=11]="SvnCommitted";ActivityType[ActivityType["GitPushed"]=12]="GitPushed";ActivityType[ActivityType["GitRepositoryCreated"]=13]="GitRepositoryCreated";ActivityType[ActivityType["IssueMultiUpdated"]=14]="IssueMultiUpdated";ActivityType[ActivityType["ProjectUserAdded"]=15]="ProjectUserAdded";ActivityType[ActivityType["ProjectUserRemoved"]=16]="ProjectUserRemoved";ActivityType[ActivityType["NotifyAdded"]=17]="NotifyAdded";ActivityType[ActivityType["PullRequestAdded"]=18]="PullRequestAdded";ActivityType[ActivityType["PullRequestUpdated"]=19]="PullRequestUpdated";ActivityType[ActivityType["PullRequestCommented"]=20]="PullRequestCommented";ActivityType[ActivityType["PullRequestMerged"]=21]="PullRequestMerged";ActivityType[ActivityType["MilestoneCreated"]=22]="MilestoneCreated";ActivityType[ActivityType["MilestoneUpdated"]=23]="MilestoneUpdated";ActivityType[ActivityType["MilestoneDeleted"]=24]="MilestoneDeleted";ActivityType[ActivityType["ProjectGroupAdded"]=25]="ProjectGroupAdded";ActivityType[ActivityType["ProjectGroupDeleted"]=26]="ProjectGroupDeleted"})(ActivityType||(exports.ActivityType=ActivityType={}));var CustomFieldType;(function(CustomFieldType){CustomFieldType[CustomFieldType["Text"]=1]="Text";CustomFieldType[CustomFieldType["TextArea"]=2]="TextArea";CustomFieldType[CustomFieldType["Numeric"]=3]="Numeric";CustomFieldType[CustomFieldType["Date"]=4]="Date";CustomFieldType[CustomFieldType["SingleList"]=5]="SingleList";CustomFieldType[CustomFieldType["MultipleList"]=6]="MultipleList";CustomFieldType[CustomFieldType["CheckBox"]=7]="CheckBox";CustomFieldType[CustomFieldType["Radio"]=8]="Radio"})(CustomFieldType||(exports.CustomFieldType=CustomFieldType={}))},{}],9:[function(require,module,exports){},{}],10:[function(require,module,exports){"use strict";var GetIntrinsic=require("get-intrinsic");var callBind=require("./");var $indexOf=callBind(GetIntrinsic("String.prototype.indexOf"));module.exports=function callBoundIntrinsic(name,allowMissing){var intrinsic=GetIntrinsic(name,!!allowMissing);if(typeof intrinsic==="function"&&$indexOf(name,".prototype.")>-1){return callBind(intrinsic)}return intrinsic}},{"./":11,"get-intrinsic":23}],11:[function(require,module,exports){"use strict";var bind=require("function-bind");var GetIntrinsic=require("get-intrinsic");var setFunctionLength=require("set-function-length");var $TypeError=require("es-errors/type");var $apply=GetIntrinsic("%Function.prototype.apply%");var $call=GetIntrinsic("%Function.prototype.call%");var $reflectApply=GetIntrinsic("%Reflect.apply%",true)||bind.call($call,$apply);var $defineProperty=require("es-define-property");var $max=GetIntrinsic("%Math.max%");module.exports=function callBind(originalFunction){if(typeof originalFunction!=="function"){throw new $TypeError("a function is required")}var func=$reflectApply(bind,$call,arguments);return setFunctionLength(func,1+$max(0,originalFunction.length-(arguments.length-1)),true)};var applyBind=function applyBind(){return $reflectApply(bind,$apply,arguments)};if($defineProperty){$defineProperty(module.exports,"apply",{value:applyBind})}else{module.exports.apply=applyBind}},{"es-define-property":13,"es-errors/type":19,"function-bind":22,"get-intrinsic":23,"set-function-length":36}],12:[function(require,module,exports){"use strict";var $defineProperty=require("es-define-property");var $SyntaxError=require("es-errors/syntax");var $TypeError=require("es-errors/type");var gopd=require("gopd");module.exports=function defineDataProperty(obj,property,value){if(!obj||typeof obj!=="object"&&typeof obj!=="function"){throw new $TypeError("`obj` must be an object or a function`")}if(typeof property!=="string"&&typeof property!=="symbol"){throw new $TypeError("`property` must be a string or a symbol`")}if(arguments.length>3&&typeof arguments[3]!=="boolean"&&arguments[3]!==null){throw new $TypeError("`nonEnumerable`, if provided, must be a boolean or null")}if(arguments.length>4&&typeof arguments[4]!=="boolean"&&arguments[4]!==null){throw new $TypeError("`nonWritable`, if provided, must be a boolean or null")}if(arguments.length>5&&typeof arguments[5]!=="boolean"&&arguments[5]!==null){throw new $TypeError("`nonConfigurable`, if provided, must be a boolean or null")}if(arguments.length>6&&typeof arguments[6]!=="boolean"){throw new $TypeError("`loose`, if provided, must be a boolean")}var nonEnumerable=arguments.length>3?arguments[3]:null;var nonWritable=arguments.length>4?arguments[4]:null;var nonConfigurable=arguments.length>5?arguments[5]:null;var loose=arguments.length>6?arguments[6]:false;var desc=!!gopd&&gopd(obj,property);if($defineProperty){$defineProperty(obj,property,{configurable:nonConfigurable===null&&desc?desc.configurable:!nonConfigurable,enumerable:nonEnumerable===null&&desc?desc.enumerable:!nonEnumerable,value:value,writable:nonWritable===null&&desc?desc.writable:!nonWritable})}else if(loose||!nonEnumerable&&!nonWritable&&!nonConfigurable){obj[property]=value}else{throw new $SyntaxError("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")}}},{"es-define-property":13,"es-errors/syntax":18,"es-errors/type":19,gopd:24}],13:[function(require,module,exports){"use strict";var GetIntrinsic=require("get-intrinsic");var $defineProperty=GetIntrinsic("%Object.defineProperty%",true)||false;if($defineProperty){try{$defineProperty({},"a",{value:1})}catch(e){$defineProperty=false}}module.exports=$defineProperty},{"get-intrinsic":23}],14:[function(require,module,exports){"use strict";module.exports=EvalError},{}],15:[function(require,module,exports){"use strict";module.exports=Error},{}],16:[function(require,module,exports){"use strict";module.exports=RangeError},{}],17:[function(require,module,exports){"use strict";module.exports=ReferenceError},{}],18:[function(require,module,exports){"use strict";module.exports=SyntaxError},{}],19:[function(require,module,exports){"use strict";module.exports=TypeError},{}],20:[function(require,module,exports){"use strict";module.exports=URIError},{}],21:[function(require,module,exports){"use strict";var ERROR_MESSAGE="Function.prototype.bind called on incompatible ";var toStr=Object.prototype.toString;var max=Math.max;var funcType="[object Function]";var concatty=function concatty(a,b){var arr=[];for(var i=0;i1&&typeof allowMissing!=="boolean"){throw new $TypeError('"allowMissing" argument must be a boolean')}if($exec(/^%?[^%]*%?$/,name)===null){throw new $SyntaxError("`%` may not be present anywhere but at the beginning and end of the intrinsic name")}var parts=stringToPath(name);var intrinsicBaseName=parts.length>0?parts[0]:"";var intrinsic=getBaseIntrinsic("%"+intrinsicBaseName+"%",allowMissing);var intrinsicRealName=intrinsic.name;var value=intrinsic.value;var skipFurtherCaching=false;var alias=intrinsic.alias;if(alias){intrinsicBaseName=alias[0];$spliceApply(parts,$concat([0,1],alias))}for(var i=1,isOwn=true;i=parts.length){var desc=$gOPD(value,part);isOwn=!!desc;if(isOwn&&"get"in desc&&!("originalValue"in desc.get)){value=desc.get}else{value=value[part]}}else{isOwn=hasOwn(value,part);value=value[part]}if(isOwn&&!skipFurtherCaching){INTRINSICS[intrinsicRealName]=value}}}return value}},{"es-errors":15,"es-errors/eval":14,"es-errors/range":16,"es-errors/ref":17,"es-errors/syntax":18,"es-errors/type":19,"es-errors/uri":20,"function-bind":22,"has-proto":26,"has-symbols":27,hasown:29}],24:[function(require,module,exports){"use strict";var GetIntrinsic=require("get-intrinsic");var $gOPD=GetIntrinsic("%Object.getOwnPropertyDescriptor%",true);if($gOPD){try{$gOPD([],"length")}catch(e){$gOPD=null}}module.exports=$gOPD},{"get-intrinsic":23}],25:[function(require,module,exports){"use strict";var $defineProperty=require("es-define-property");var hasPropertyDescriptors=function hasPropertyDescriptors(){return!!$defineProperty};hasPropertyDescriptors.hasArrayLengthDefineBug=function hasArrayLengthDefineBug(){if(!$defineProperty){return null}try{return $defineProperty([],"length",{value:1}).length!==1}catch(e){return true}};module.exports=hasPropertyDescriptors},{"es-define-property":13}],26:[function(require,module,exports){"use strict";var test={__proto__:null,foo:{}};var $Object=Object;module.exports=function hasProto(){return{__proto__:test}.foo===test.foo&&!(test instanceof $Object)}},{}],27:[function(require,module,exports){"use strict";var origSymbol=typeof Symbol!=="undefined"&&Symbol;var hasSymbolSham=require("./shams");module.exports=function hasNativeSymbols(){if(typeof origSymbol!=="function"){return false}if(typeof Symbol!=="function"){return false}if(typeof origSymbol("foo")!=="symbol"){return false}if(typeof Symbol("bar")!=="symbol"){return false}return hasSymbolSham()}},{"./shams":28}],28:[function(require,module,exports){"use strict";module.exports=function hasSymbols(){if(typeof Symbol!=="function"||typeof Object.getOwnPropertySymbols!=="function"){return false}if(typeof Symbol.iterator==="symbol"){return true}var obj={};var sym=Symbol("test");var symObj=Object(sym);if(typeof sym==="string"){return false}if(Object.prototype.toString.call(sym)!=="[object Symbol]"){return false}if(Object.prototype.toString.call(symObj)!=="[object Symbol]"){return false}var symVal=42;obj[sym]=symVal;for(sym in obj){return false}if(typeof Object.keys==="function"&&Object.keys(obj).length!==0){return false}if(typeof Object.getOwnPropertyNames==="function"&&Object.getOwnPropertyNames(obj).length!==0){return false}var syms=Object.getOwnPropertySymbols(obj);if(syms.length!==1||syms[0]!==sym){return false}if(!Object.prototype.propertyIsEnumerable.call(obj,sym)){return false}if(typeof Object.getOwnPropertyDescriptor==="function"){var descriptor=Object.getOwnPropertyDescriptor(obj,sym);if(descriptor.value!==symVal||descriptor.enumerable!==true){return false}}return true}},{}],29:[function(require,module,exports){"use strict";var call=Function.prototype.call;var $hasOwn=Object.prototype.hasOwnProperty;var bind=require("function-bind");module.exports=bind.call(call,$hasOwn)},{"function-bind":22}],30:[function(require,module,exports){(function(global){(function(){var hasMap=typeof Map==="function"&&Map.prototype;var mapSizeDescriptor=Object.getOwnPropertyDescriptor&&hasMap?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null;var mapSize=hasMap&&mapSizeDescriptor&&typeof mapSizeDescriptor.get==="function"?mapSizeDescriptor.get:null;var mapForEach=hasMap&&Map.prototype.forEach;var hasSet=typeof Set==="function"&&Set.prototype;var setSizeDescriptor=Object.getOwnPropertyDescriptor&&hasSet?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null;var setSize=hasSet&&setSizeDescriptor&&typeof setSizeDescriptor.get==="function"?setSizeDescriptor.get:null;var setForEach=hasSet&&Set.prototype.forEach;var hasWeakMap=typeof WeakMap==="function"&&WeakMap.prototype;var weakMapHas=hasWeakMap?WeakMap.prototype.has:null;var hasWeakSet=typeof WeakSet==="function"&&WeakSet.prototype;var weakSetHas=hasWeakSet?WeakSet.prototype.has:null;var hasWeakRef=typeof WeakRef==="function"&&WeakRef.prototype;var weakRefDeref=hasWeakRef?WeakRef.prototype.deref:null;var booleanValueOf=Boolean.prototype.valueOf;var objectToString=Object.prototype.toString;var functionToString=Function.prototype.toString;var $match=String.prototype.match;var $slice=String.prototype.slice;var $replace=String.prototype.replace;var $toUpperCase=String.prototype.toUpperCase;var $toLowerCase=String.prototype.toLowerCase;var $test=RegExp.prototype.test;var $concat=Array.prototype.concat;var $join=Array.prototype.join;var $arrSlice=Array.prototype.slice;var $floor=Math.floor;var bigIntValueOf=typeof BigInt==="function"?BigInt.prototype.valueOf:null;var gOPS=Object.getOwnPropertySymbols;var symToString=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?Symbol.prototype.toString:null;var hasShammedSymbols=typeof Symbol==="function"&&typeof Symbol.iterator==="object";var toStringTag=typeof Symbol==="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===hasShammedSymbols?"object":"symbol")?Symbol.toStringTag:null;var isEnumerable=Object.prototype.propertyIsEnumerable;var gPO=(typeof Reflect==="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(O){return O.__proto__}:null);function addNumericSeparator(num,str){if(num===Infinity||num===-Infinity||num!==num||num&&num>-1e3&&num<1e3||$test.call(/e/,str)){return str}var sepRegex=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof num==="number"){var int=num<0?-$floor(-num):$floor(num);if(int!==num){var intStr=String(int);var dec=$slice.call(str,intStr.length+1);return $replace.call(intStr,sepRegex,"$&_")+"."+$replace.call($replace.call(dec,/([0-9]{3})/g,"$&_"),/_$/,"")}}return $replace.call(str,sepRegex,"$&_")}var utilInspect=require("./util.inspect");var inspectCustom=utilInspect.custom;var inspectSymbol=isSymbol(inspectCustom)?inspectCustom:null;module.exports=function inspect_(obj,options,depth,seen){var opts=options||{};if(has(opts,"quoteStyle")&&(opts.quoteStyle!=="single"&&opts.quoteStyle!=="double")){throw new TypeError('option "quoteStyle" must be "single" or "double"')}if(has(opts,"maxStringLength")&&(typeof opts.maxStringLength==="number"?opts.maxStringLength<0&&opts.maxStringLength!==Infinity:opts.maxStringLength!==null)){throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`')}var customInspect=has(opts,"customInspect")?opts.customInspect:true;if(typeof customInspect!=="boolean"&&customInspect!=="symbol"){throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`")}if(has(opts,"indent")&&opts.indent!==null&&opts.indent!=="\t"&&!(parseInt(opts.indent,10)===opts.indent&&opts.indent>0)){throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`')}if(has(opts,"numericSeparator")&&typeof opts.numericSeparator!=="boolean"){throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`')}var numericSeparator=opts.numericSeparator;if(typeof obj==="undefined"){return"undefined"}if(obj===null){return"null"}if(typeof obj==="boolean"){return obj?"true":"false"}if(typeof obj==="string"){return inspectString(obj,opts)}if(typeof obj==="number"){if(obj===0){return Infinity/obj>0?"0":"-0"}var str=String(obj);return numericSeparator?addNumericSeparator(obj,str):str}if(typeof obj==="bigint"){var bigIntStr=String(obj)+"n";return numericSeparator?addNumericSeparator(obj,bigIntStr):bigIntStr}var maxDepth=typeof opts.depth==="undefined"?5:opts.depth;if(typeof depth==="undefined"){depth=0}if(depth>=maxDepth&&maxDepth>0&&typeof obj==="object"){return isArray(obj)?"[Array]":"[Object]"}var indent=getIndent(opts,depth);if(typeof seen==="undefined"){seen=[]}else if(indexOf(seen,obj)>=0){return"[Circular]"}function inspect(value,from,noIndent){if(from){seen=$arrSlice.call(seen);seen.push(from)}if(noIndent){var newOpts={depth:opts.depth};if(has(opts,"quoteStyle")){newOpts.quoteStyle=opts.quoteStyle}return inspect_(value,newOpts,depth+1,seen)}return inspect_(value,opts,depth+1,seen)}if(typeof obj==="function"&&!isRegExp(obj)){var name=nameOf(obj);var keys=arrObjKeys(obj,inspect);return"[Function"+(name?": "+name:" (anonymous)")+"]"+(keys.length>0?" { "+$join.call(keys,", ")+" }":"")}if(isSymbol(obj)){var symString=hasShammedSymbols?$replace.call(String(obj),/^(Symbol\(.*\))_[^)]*$/,"$1"):symToString.call(obj);return typeof obj==="object"&&!hasShammedSymbols?markBoxed(symString):symString}if(isElement(obj)){var s="<"+$toLowerCase.call(String(obj.nodeName));var attrs=obj.attributes||[];for(var i=0;i";return s}if(isArray(obj)){if(obj.length===0){return"[]"}var xs=arrObjKeys(obj,inspect);if(indent&&!singleLineValues(xs)){return"["+indentedJoin(xs,indent)+"]"}return"[ "+$join.call(xs,", ")+" ]"}if(isError(obj)){var parts=arrObjKeys(obj,inspect);if(!("cause"in Error.prototype)&&"cause"in obj&&!isEnumerable.call(obj,"cause")){return"{ ["+String(obj)+"] "+$join.call($concat.call("[cause]: "+inspect(obj.cause),parts),", ")+" }"}if(parts.length===0){return"["+String(obj)+"]"}return"{ ["+String(obj)+"] "+$join.call(parts,", ")+" }"}if(typeof obj==="object"&&customInspect){if(inspectSymbol&&typeof obj[inspectSymbol]==="function"&&utilInspect){return utilInspect(obj,{depth:maxDepth-depth})}else if(customInspect!=="symbol"&&typeof obj.inspect==="function"){return obj.inspect()}}if(isMap(obj)){var mapParts=[];if(mapForEach){mapForEach.call(obj,function(value,key){mapParts.push(inspect(key,obj,true)+" => "+inspect(value,obj))})}return collectionOf("Map",mapSize.call(obj),mapParts,indent)}if(isSet(obj)){var setParts=[];if(setForEach){setForEach.call(obj,function(value){setParts.push(inspect(value,obj))})}return collectionOf("Set",setSize.call(obj),setParts,indent)}if(isWeakMap(obj)){return weakCollectionOf("WeakMap")}if(isWeakSet(obj)){return weakCollectionOf("WeakSet")}if(isWeakRef(obj)){return weakCollectionOf("WeakRef")}if(isNumber(obj)){return markBoxed(inspect(Number(obj)))}if(isBigInt(obj)){return markBoxed(inspect(bigIntValueOf.call(obj)))}if(isBoolean(obj)){return markBoxed(booleanValueOf.call(obj))}if(isString(obj)){return markBoxed(inspect(String(obj)))}if(typeof window!=="undefined"&&obj===window){return"{ [object Window] }"}if(typeof globalThis!=="undefined"&&obj===globalThis||typeof global!=="undefined"&&obj===global){return"{ [object globalThis] }"}if(!isDate(obj)&&!isRegExp(obj)){var ys=arrObjKeys(obj,inspect);var isPlainObject=gPO?gPO(obj)===Object.prototype:obj instanceof Object||obj.constructor===Object;var protoTag=obj instanceof Object?"":"null prototype";var stringTag=!isPlainObject&&toStringTag&&Object(obj)===obj&&toStringTag in obj?$slice.call(toStr(obj),8,-1):protoTag?"Object":"";var constructorTag=isPlainObject||typeof obj.constructor!=="function"?"":obj.constructor.name?obj.constructor.name+" ":"";var tag=constructorTag+(stringTag||protoTag?"["+$join.call($concat.call([],stringTag||[],protoTag||[]),": ")+"] ":"");if(ys.length===0){return tag+"{}"}if(indent){return tag+"{"+indentedJoin(ys,indent)+"}"}return tag+"{ "+$join.call(ys,", ")+" }"}return String(obj)};function wrapQuotes(s,defaultStyle,opts){var quoteChar=(opts.quoteStyle||defaultStyle)==="double"?'"':"'";return quoteChar+s+quoteChar}function quote(s){return $replace.call(String(s),/"/g,""")}function isArray(obj){return toStr(obj)==="[object Array]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isDate(obj){return toStr(obj)==="[object Date]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isRegExp(obj){return toStr(obj)==="[object RegExp]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isError(obj){return toStr(obj)==="[object Error]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isString(obj){return toStr(obj)==="[object String]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isNumber(obj){return toStr(obj)==="[object Number]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isBoolean(obj){return toStr(obj)==="[object Boolean]"&&(!toStringTag||!(typeof obj==="object"&&toStringTag in obj))}function isSymbol(obj){if(hasShammedSymbols){return obj&&typeof obj==="object"&&obj instanceof Symbol}if(typeof obj==="symbol"){return true}if(!obj||typeof obj!=="object"||!symToString){return false}try{symToString.call(obj);return true}catch(e){}return false}function isBigInt(obj){if(!obj||typeof obj!=="object"||!bigIntValueOf){return false}try{bigIntValueOf.call(obj);return true}catch(e){}return false}var hasOwn=Object.prototype.hasOwnProperty||function(key){return key in this};function has(obj,key){return hasOwn.call(obj,key)}function toStr(obj){return objectToString.call(obj)}function nameOf(f){if(f.name){return f.name}var m=$match.call(functionToString.call(f),/^function\s*([\w$]+)/);if(m){return m[1]}return null}function indexOf(xs,x){if(xs.indexOf){return xs.indexOf(x)}for(var i=0,l=xs.length;iopts.maxStringLength){var remaining=str.length-opts.maxStringLength;var trailer="... "+remaining+" more character"+(remaining>1?"s":"");return inspectString($slice.call(str,0,opts.maxStringLength),opts)+trailer}var s=$replace.call($replace.call(str,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,lowbyte);return wrapQuotes(s,"single",opts)}function lowbyte(c){var n=c.charCodeAt(0);var x={8:"b",9:"t",10:"n",12:"f",13:"r"}[n];if(x){return"\\"+x}return"\\x"+(n<16?"0":"")+$toUpperCase.call(n.toString(16))}function markBoxed(str){return"Object("+str+")"}function weakCollectionOf(type){return type+" { ? }"}function collectionOf(type,size,entries,indent){var joinedEntries=indent?indentedJoin(entries,indent):$join.call(entries,", ");return type+" ("+size+") {"+joinedEntries+"}"}function singleLineValues(xs){for(var i=0;i=0){return false}}return true}function getIndent(opts,depth){var baseIndent;if(opts.indent==="\t"){baseIndent="\t"}else if(typeof opts.indent==="number"&&opts.indent>0){baseIndent=$join.call(Array(opts.indent+1)," ")}else{return null}return{base:baseIndent,prev:$join.call(Array(depth+1),baseIndent)}}function indentedJoin(xs,indent){if(xs.length===0){return""}var lineJoiner="\n"+indent.prev+indent.base;return lineJoiner+$join.call(xs,","+lineJoiner)+"\n"+indent.prev}function arrObjKeys(obj,inspect){var isArr=isArray(obj);var xs=[];if(isArr){xs.length=obj.length;for(var i=0;i-1){return val.split(",")}return val};var isoSentinel="utf8=%26%2310003%3B";var charsetSentinel="utf8=%E2%9C%93";var parseValues=function parseQueryStringValues(str,options){var obj={__proto__:null};var cleanStr=options.ignoreQueryPrefix?str.replace(/^\?/,""):str;var limit=options.parameterLimit===Infinity?undefined:options.parameterLimit;var parts=cleanStr.split(options.delimiter,limit);var skipIndex=-1;var i;var charset=options.charset;if(options.charsetSentinel){for(i=0;i-1){val=isArray(val)?[val]:val}var existing=has.call(obj,key);if(existing&&options.duplicates==="combine"){obj[key]=utils.combine(obj[key],val)}else if(!existing||options.duplicates==="last"){obj[key]=val}}return obj};var parseObject=function(chain,val,options,valuesParsed){var leaf=valuesParsed?val:parseArrayValue(val,options);for(var i=chain.length-1;i>=0;--i){var obj;var root=chain[i];if(root==="[]"&&options.parseArrays){obj=options.allowEmptyArrays&&leaf===""?[]:[].concat(leaf)}else{obj=options.plainObjects?Object.create(null):{};var cleanRoot=root.charAt(0)==="["&&root.charAt(root.length-1)==="]"?root.slice(1,-1):root;var decodedRoot=options.decodeDotInKeys?cleanRoot.replace(/%2E/g,"."):cleanRoot;var index=parseInt(decodedRoot,10);if(!options.parseArrays&&decodedRoot===""){obj={0:leaf}}else if(!isNaN(index)&&root!==decodedRoot&&String(index)===decodedRoot&&index>=0&&(options.parseArrays&&index<=options.arrayLimit)){obj=[];obj[index]=leaf}else if(decodedRoot!=="__proto__"){obj[decodedRoot]=leaf}}leaf=obj}return leaf};var parseKeys=function parseQueryStringKeys(givenKey,val,options,valuesParsed){if(!givenKey){return}var key=options.allowDots?givenKey.replace(/\.([^.[]+)/g,"[$1]"):givenKey;var brackets=/(\[[^[\]]*])/;var child=/(\[[^[\]]*])/g;var segment=options.depth>0&&brackets.exec(key);var parent=segment?key.slice(0,segment.index):key;var keys=[];if(parent){if(!options.plainObjects&&has.call(Object.prototype,parent)){if(!options.allowPrototypes){return}}keys.push(parent)}var i=0;while(options.depth>0&&(segment=child.exec(key))!==null&&i0?obj.join(",")||null:void undefined}]}else if(isArray(filter)){objKeys=filter}else{var keys=Object.keys(obj);objKeys=sort?keys.sort(sort):keys}var encodedPrefix=encodeDotInKeys?prefix.replace(/\./g,"%2E"):prefix;var adjustedPrefix=commaRoundTrip&&isArray(obj)&&obj.length===1?encodedPrefix+"[]":encodedPrefix;if(allowEmptyArrays&&isArray(obj)&&obj.length===0){return adjustedPrefix+"[]"}for(var j=0;j0?prefix+joined:""}},{"./formats":31,"./utils":35,"side-channel":37}],35:[function(require,module,exports){"use strict";var formats=require("./formats");var has=Object.prototype.hasOwnProperty;var isArray=Array.isArray;var hexTable=function(){var array=[];for(var i=0;i<256;++i){array.push("%"+((i<16?"0":"")+i.toString(16)).toUpperCase())}return array}();var compactQueue=function compactQueue(queue){while(queue.length>1){var item=queue.pop();var obj=item.obj[item.prop];if(isArray(obj)){var compacted=[];for(var j=0;j=limit?string.slice(j,j+limit):string;var arr=[];for(var i=0;i=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122||format===formats.RFC1738&&(c===40||c===41)){arr[arr.length]=segment.charAt(i);continue}if(c<128){arr[arr.length]=hexTable[c];continue}if(c<2048){arr[arr.length]=hexTable[192|c>>6]+hexTable[128|c&63];continue}if(c<55296||c>=57344){arr[arr.length]=hexTable[224|c>>12]+hexTable[128|c>>6&63]+hexTable[128|c&63];continue}i+=1;c=65536+((c&1023)<<10|segment.charCodeAt(i)&1023);arr[arr.length]=hexTable[240|c>>18]+hexTable[128|c>>12&63]+hexTable[128|c>>6&63]+hexTable[128|c&63]}out+=arr.join("")}return out};var compact=function compact(value){var queue=[{obj:{o:value},prop:"o"}];var refs=[];for(var i=0;i4294967295||$floor(length)!==length){throw new $TypeError("`length` must be a positive 32-bit integer")}var loose=arguments.length>2&&!!arguments[2];var functionLengthIsConfigurable=true;var functionLengthIsWritable=true;if("length"in fn&&gOPD){var desc=gOPD(fn,"length");if(desc&&!desc.configurable){functionLengthIsConfigurable=false}if(desc&&!desc.writable){functionLengthIsWritable=false}}if(functionLengthIsConfigurable||functionLengthIsWritable||!loose){if(hasDescriptors){define(fn,"length",length,true,true)}else{define(fn,"length",length)}}return fn}},{"define-data-property":12,"es-errors/type":19,"get-intrinsic":23,gopd:24,"has-property-descriptors":25}],37:[function(require,module,exports){"use strict";var GetIntrinsic=require("get-intrinsic");var callBound=require("call-bind/callBound");var inspect=require("object-inspect");var $TypeError=require("es-errors/type");var $WeakMap=GetIntrinsic("%WeakMap%",true);var $Map=GetIntrinsic("%Map%",true);var $weakMapGet=callBound("WeakMap.prototype.get",true);var $weakMapSet=callBound("WeakMap.prototype.set",true);var $weakMapHas=callBound("WeakMap.prototype.has",true);var $mapGet=callBound("Map.prototype.get",true);var $mapSet=callBound("Map.prototype.set",true);var $mapHas=callBound("Map.prototype.has",true);var listGetNode=function(list,key){var prev=list;var curr;for(;(curr=prev.next)!==null;prev=curr){if(curr.key===key){prev.next=curr.next;curr.next=list.next;list.next=curr;return curr}}};var listGet=function(objects,key){var node=listGetNode(objects,key);return node&&node.value};var listSet=function(objects,key,value){var node=listGetNode(objects,key);if(node){node.value=value}else{objects.next={key:key,next:objects.next,value:value}}};var listHas=function(objects,key){return!!listGetNode(objects,key)};module.exports=function getSideChannel(){var $wm;var $m;var $o;var channel={assert:function(key){if(!channel.has(key)){throw new $TypeError("Side channel does not contain "+inspect(key))}},get:function(key){if($WeakMap&&key&&(typeof key==="object"||typeof key==="function")){if($wm){return $weakMapGet($wm,key)}}else if($Map){if($m){return $mapGet($m,key)}}else{if($o){return listGet($o,key)}}},has:function(key){if($WeakMap&&key&&(typeof key==="object"||typeof key==="function")){if($wm){return $weakMapHas($wm,key)}}else if($Map){if($m){return $mapHas($m,key)}}else{if($o){return listHas($o,key)}}return false},set:function(key,value){if($WeakMap&&key&&(typeof key==="object"||typeof key==="function")){if(!$wm){$wm=new $WeakMap}$weakMapSet($wm,key,value)}else if($Map){if(!$m){$m=new $Map}$mapSet($m,key,value)}else{if(!$o){$o={key:{},next:null}}listSet($o,key,value)}}};return channel}},{"call-bind/callBound":10,"es-errors/type":19,"get-intrinsic":23,"object-inspect":30}]},{},[4])(4)}); \ No newline at end of file diff --git a/dist/types/backlog.d.ts b/dist/types/backlog.d.ts index 871b212..112ab30 100644 --- a/dist/types/backlog.d.ts +++ b/dist/types/backlog.d.ts @@ -328,8 +328,13 @@ export default class Backlog extends Request { getIssue(issueIdOrKey: string | number): Promise; /** * https://developer.nulab.com/docs/backlog/api/2/delete-issue/ + * @deprecated Renamed to `deleteIssue`. */ deleteIssuesCount(issueIdOrKey: string | number): Promise; + /** + * https://developer.nulab.com/docs/backlog/api/2/delete-issue/ + */ + deleteIssue(issueIdOrKey: string | number): Promise; /** * https://developer.nulab.com/docs/backlog/api/2/get-comment-list/ */ diff --git a/src/backlog.ts b/src/backlog.ts index 54b441c..1d48883 100644 --- a/src/backlog.ts +++ b/src/backlog.ts @@ -657,8 +657,16 @@ export default class Backlog extends Request { /** * https://developer.nulab.com/docs/backlog/api/2/delete-issue/ + * @deprecated Renamed to `deleteIssue`. */ public deleteIssuesCount(issueIdOrKey: string | number): Promise { + return this.deleteIssue(issueIdOrKey); + } + + /** + * https://developer.nulab.com/docs/backlog/api/2/delete-issue/ + */ + public deleteIssue(issueIdOrKey: string | number): Promise { return this.delete(`issues/${issueIdOrKey}`); }