Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@octokit/request

Package Overview
Dependencies
Maintainers
3
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 1.1.0 to 1.1.1

20

lib/http-error.js

@@ -1,24 +0,14 @@

'use strict'
const STATUS_CODES = {
304: 'Not Modified', // See PR #673 (https://github.com/octokit/rest.js/pull/673)
400: 'Bad Request',
404: 'Not Found',
500: 'Internal Server Error',
504: 'Gateway Timeout'
}
module.exports = class HttpError extends Error {
constructor (message, code, headers) {
constructor (message, code) {
super(message)
// Maintains proper stack trace for where our error was thrown (only available on V8)
/* istanbul ignore else */
// Maintains proper stack trace (only available on V8)
/* istanbul ignore next */
if (Error.captureStackTrace) {
Error.captureStackTrace(this, this.constructor)
}
this.name = 'HttpError'
this.code = code
this.status = STATUS_CODES[code]
this.headers = headers
}
}
{
"name": "@octokit/request",
"version": "1.1.0",
"version": "1.1.1",
"publishConfig": {

@@ -5,0 +5,0 @@ "access": "public"

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