resolve = (alias, callback, index) => {
					const newRequest = `${requestPath.slice(
						0,
						-extension.length,
					)}${alias}`;

					return resolver.doResolve(
						target,
						{
							...request,
							request: newRequest,
							fullySpecified: true,
						},
						`aliased from extension alias with mapping '${extension}' to '${alias}'`,
						resolveContext,
						(err, result) => {
							// Throw error if we are on the last alias (for multiple aliases) and it failed, always throw if we are not an array or we have only one alias
							if (!isAliasString && index) {
								if (index !== this.options.alias.length) {
									if (resolveContext.log) {
										resolveContext.log(
											`Failed to alias from extension alias with mapping '${extension}' to '${alias}' for '${newRequest}': ${err}`,
										);
									}

									return callback(null, result);
								}

								return callback(err, result);
							}
							callback(err, result);
						},
					);
				}
@param {string} alias extension alias
@param {(err?: null | Error, result?: null|ResolveRequest) => void} callback callback
@param {number=} index index
@returns {void}