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

dextrose

Package Overview
Dependencies
Maintainers
3
Versions
73
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dextrose - npm Package Compare versions

Comparing version 1.2.9 to 1.2.10

2

lib/native-snapper.js

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

var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();var _logger=require("./logger");var _logger2=_interopRequireDefault(_logger);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj};}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}var _require=require("child_process"),execSync=_require.execSync;module.exports=function(){function Snapper(platform){_classCallCheck(this,Snapper);this.platform=platform.toLowerCase();}_createClass(Snapper,[{key:"snap",value:function snap(outputPath){var _this=this;if(typeof outputPath!=='string'){throw Error("Output path should be a string recieved: "+outputPath);}return new Promise(function(resolve){var outputPathWithExtension=outputPath+"."+_this.platform+".png";_logger2.default.verbose('native-snapper',"taking snapshot at path: "+outputPathWithExtension);execSync("../node_modules/.bin/osnap "+_this.platform+" -f "+outputPathWithExtension);resolve();});}}]);return Snapper;}();
var _createClass=function(){function defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,descriptor.key,descriptor);}}return function(Constructor,protoProps,staticProps){if(protoProps)defineProperties(Constructor.prototype,protoProps);if(staticProps)defineProperties(Constructor,staticProps);return Constructor;};}();var _logger=require("./logger");var _logger2=_interopRequireDefault(_logger);var _path=require("path");var _path2=_interopRequireDefault(_path);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj};}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}var _require=require("child_process"),execSync=_require.execSync;module.exports=function(){function Snapper(platform){_classCallCheck(this,Snapper);this.platform=platform.toLowerCase();}_createClass(Snapper,[{key:"snap",value:function snap(outputPath){var _this=this;if(typeof outputPath!=='string'){throw Error("Output path should be a string recieved: "+outputPath);}return new Promise(function(resolve){var outputPathWithExtension=outputPath+"."+_this.platform+".png";_logger2.default.verbose('native-snapper',"taking snapshot at path: "+outputPathWithExtension);execSync(_path2.default.join(__dirname,'../node_modules/.bin/osnap ')+(_this.platform+" -f "+outputPathWithExtension));resolve();});}}]);return Snapper;}();
{
"name": "dextrose",
"version": "1.2.9",
"version": "1.2.10",
"author": "NewsUk",

@@ -5,0 +5,0 @@ "license": "MIT",

import log from "./logger";
import path from "path";
const {

@@ -19,4 +21,5 @@ execSync

log.verbose('native-snapper', `taking snapshot at path: ${outputPathWithExtension}`)
// TODO: need to make this reject if fails
execSync(`../node_modules/.bin/osnap ${this.platform} -f ${outputPathWithExtension}`);
execSync(path.join(__dirname, '../node_modules/.bin/osnap ') + `${this.platform} -f ${outputPathWithExtension}`);
resolve();

@@ -23,0 +26,0 @@ });

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