Socket
Socket
Sign inDemoInstall

@octokit/request

Package Overview
Dependencies
Maintainers
0
Versions
104
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@octokit/request - npm Package Compare versions

Comparing version 9.1.2 to 9.1.3

17

dist-bundle/index.js

@@ -138,14 +138,11 @@ // pkg/dist-src/index.js

function toErrorMessage(data) {
if (typeof data === "string") return data;
let suffix;
if ("documentation_url" in data) {
suffix = ` - ${data.documentation_url}`;
} else {
suffix = "";
if (typeof data === "string") {
return data;
}
if (data instanceof ArrayBuffer) {
return "Unknown error";
}
if ("message" in data) {
if (Array.isArray(data.errors)) {
return `${data.message}: ${data.errors.map(JSON.stringify).join(", ")}${suffix}`;
}
return `${data.message}${suffix}`;
const suffix = "documentation_url" in data ? ` - ${data.documentation_url}` : "";
return Array.isArray(data.errors) ? `${data.message}: ${data.errors.map((v) => JSON.stringify(v)).join(", ")}${suffix}` : `${data.message}${suffix}`;
}

@@ -152,0 +149,0 @@ return `Unknown error: ${JSON.stringify(data)}`;

@@ -112,14 +112,11 @@ import { isPlainObject } from "./is-plain-object.js";

function toErrorMessage(data) {
if (typeof data === "string") return data;
let suffix;
if ("documentation_url" in data) {
suffix = ` - ${data.documentation_url}`;
} else {
suffix = "";
if (typeof data === "string") {
return data;
}
if (data instanceof ArrayBuffer) {
return "Unknown error";
}
if ("message" in data) {
if (Array.isArray(data.errors)) {
return `${data.message}: ${data.errors.map(JSON.stringify).join(", ")}${suffix}`;
}
return `${data.message}${suffix}`;
const suffix = "documentation_url" in data ? ` - ${data.documentation_url}` : "";
return Array.isArray(data.errors) ? `${data.message}: ${data.errors.map((v) => JSON.stringify(v)).join(", ")}${suffix}` : `${data.message}${suffix}`;
}

@@ -126,0 +123,0 @@ return `Unknown error: ${JSON.stringify(data)}`;

@@ -1,4 +0,4 @@

const VERSION = "9.1.2";
const VERSION = "9.1.3";
export {
VERSION
};

@@ -1,1 +0,1 @@

export declare const VERSION = "9.1.2";
export declare const VERSION = "9.1.3";
{
"name": "@octokit/request",
"version": "9.1.2",
"version": "9.1.3",
"type": "module",

@@ -33,3 +33,3 @@ "publishConfig": {

"glob": "^10.2.4",
"prettier": "3.3.2",
"prettier": "3.3.3",
"semantic-release-plugin-update-version-in-files": "^1.0.0",

@@ -36,0 +36,0 @@ "typescript": "^5.0.0",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc