New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@st-graphics/premium

Package Overview
Dependencies
Maintainers
1
Versions
22
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@st-graphics/premium - npm Package Compare versions

Comparing version 0.2.5 to 0.2.6

48

client/premium.js

@@ -43,4 +43,2 @@ const inProduction = process.env.NODE_ENV === 'production'

window.fetch = window.fetch || fetch
function PremiumClient () {}

@@ -101,48 +99,2 @@

function fetch (url, options) {
options = options || {}
options.method = options.method || 'GET'
options.headers = options.headers || {}
return new Promise(function (resolve, reject) {
const xhr = new window.XMLHttpRequest()
xhr.open(options.method, url)
Object.keys(options.headers).forEach(function (key) {
xhr.setRequestHeader(key, options.headers[key])
})
xhr.withCredentials = options.credentials === 'include'
xhr.onreadystatechange = function () {
if (xhr.readyState === 4) {
try {
const response = Object.create({
text () {
return xhr.responseText
},
json () {
return JSON.parse(xhr.responseText)
}
})
response.ok = xhr.status === 200
response.status = xhr.status
response.statusText = xhr.statusText
response.url = xhr.responseURL
response.headers = xhr.getAllResponseHeaders()
resolve(response)
} catch (err) {
reject(err)
}
}
}
xhr.onerror = function () {
reject(new Error('Network error'))
}
xhr.onabort = function () {
reject(new Error('Aborted'))
}
xhr.ontimeout = function () {
reject(new Error('Timed out'))
}
xhr.send(options.body)
})
}
function getLocation () {

@@ -149,0 +101,0 @@ const w = window.top

2

package.json
{
"name": "@st-graphics/premium",
"version": "0.2.5",
"version": "0.2.6",
"description": "ST Graphics Premium implementation",

@@ -5,0 +5,0 @@ "main": "client/premium.js",

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