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

fontscan

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fontscan - npm Package Compare versions

Comparing version 0.2.5 to 0.2.6

17

dist/fontDescriptor.js

@@ -17,5 +17,5 @@ "use strict";

this.path = path;
this.postscriptName = fixGarbled(font.postscriptName.toString());
this.family = fixGarbled(font.familyName.toString());
this.style = fixGarbled(font.subfamilyName.toString());
this.postscriptName = fixIncorrectString(font.postscriptName);
this.family = fixIncorrectString(font.familyName);
this.style = fixIncorrectString(font.subfamilyName);
var isFixedPitch = (_a = font.post) === null || _a === void 0 ? void 0 : _a.isFixedPitch;

@@ -44,5 +44,12 @@ this.monospace = isFixedPitch !== 0;

exports.FontDescriptor = FontDescriptor;
function fixGarbled(str) {
return str.replace(/\\u0000/g, '');
function fixIncorrectString(str) {
if (typeof str === 'string')
return str;
var newStr = '';
for (var i = 0; i < str.length; i++) {
if (str[i] !== 0)
newStr += Buffer.from([str[i]]).toString();
}
return newStr;
}
//# sourceMappingURL=fontDescriptor.js.map
{
"name": "fontscan",
"version": "0.2.5",
"version": "0.2.6",
"description": "Get font list in specified directory(default system fonts).",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

Sorry, the diff of this file is not supported yet

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