Socket
Socket
Sign inDemoInstall

cloudinary-microurl

Package Overview
Dependencies
0
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.1 to 1.0.2

2

package.json
{
"name": "cloudinary-microurl",
"version": "1.0.1",
"version": "1.0.2",
"description": "A tiny library to generate cloudinary URLs from options objects",

@@ -5,0 +5,0 @@ "main": "url.js",

@@ -13,3 +13,3 @@ // Example options:

const TYPES = [
var TYPES = [
{name: 'crop', prefix:'c'},

@@ -29,7 +29,7 @@ {name: 'effect', prefix:'e'},

const scheme = options.secure ? 'https' : 'http';
const cloud_name = options.cloud_name;
var scheme = options.secure ? 'https' : 'http';
var cloud_name = options.cloud_name;
if (!cloud_name) throw Error('Missing required options.cloud_name');
const params = [];
var params = [];

@@ -41,3 +41,3 @@ for (var i = 0; i < TYPES.length; i++) {

if (Array.isArray(options[name])) {
options[name].forEach(opt => params.push(prefix + '_' + opt));
options[name].forEach(function(opt) {params.push(prefix + '_' + opt)});
} else if (options[name] != null) {

@@ -48,3 +48,3 @@ params.push(prefix + '_' + options[name]);

const urlParams = params.length ? params.join(',') + '/' : '';
var urlParams = params.length ? params.join(',') + '/' : '';
return scheme + '://res.cloudinary.com/'

@@ -51,0 +51,0 @@ + encodeURIComponent(options.cloud_name)

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc