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

gulp-locale-filter

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gulp-locale-filter - npm Package Compare versions

Comparing version 1.2.0 to 1.2.1

13

lib/plugin/filter/filter-command.js

@@ -8,3 +8,3 @@ "use strict";

var plugin_config_1 = require("../plugin-config");
var mapFileCommentRegex = /(?:(\/\/[@#][ \t]+sourceMappingURL=)([^\s'"]+?)([ \t]*)$)|(?:(\/\*[@#][ \t]+sourceMappingURL=)([^\*]+?)([ \t]*\*\/[ \t]*)$)/gm;
var mapFileCommentRegex = /(?:(\/\/[@#][ \t]+sourceMappingURL=\/?)([^\s'"]+?)([ \t]*)$)|(?:(\/\*[@#][ \t]+sourceMappingURL=\/?)([^\*]+?)([ \t]*\*\/[ \t]*)$)/gm;
/**

@@ -66,6 +66,11 @@ * Represents the command.

var contents = file.contents.toString();
contents = contents.replace(mapFileCommentRegex, function (match, before, mapFilePath, after) {
if (mapFilePath.trim() === path.basename(file.path) + ".map") {
return before + (path.basename(basePath_1) + ".map") + after;
contents = contents.replace(mapFileCommentRegex, function (match) {
var groups = [];
for (var _i = 1; _i < arguments.length; _i++) {
groups[_i - 1] = arguments[_i];
}
var offset = groups[0] != null ? 0 : 3;
if (groups[offset + 1] === path.basename(file.path) + ".map") {
return groups[offset] + (path.basename(basePath_1) + ".map") + groups[offset + 2];
}
return match;

@@ -72,0 +77,0 @@ });

{
"name": "gulp-locale-filter",
"version": "1.2.0",
"version": "1.2.1",
"description": "Gulp plugin that filters files in the stream based on locale or language codes in the file paths.",

@@ -5,0 +5,0 @@ "keywords": [

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