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

@alttiri/util-node-js

Package Overview
Dependencies
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@alttiri/util-node-js - npm Package Compare versions

Comparing version

to
2.0.6

2

package.json
{
"name": "@alttiri/util-node-js",
"version": "2.0.5",
"version": "2.0.6",
"description": "Some Node.js util functions for personal use",

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

/// <reference types="node" />
import { Dirent } from "node:fs";
import { ListEntryBaseEx, ListEntryDirent, ListEntryDirentError, ListEntryDirentLink, ListEntryStats } from "./types/ListEntry";
import { ListEntryBaseEx, ListEntryDirent, ListEntryDirentError, ListEntryDirentLink, ListEntryStats, ListEntryStatsAny } from "./types/ListEntry";
import { IOError } from "./types/IOError";

@@ -12,2 +12,2 @@ import { FileListingSetting } from "./settings";

/** 100 lines of code to handle edge cases to create the root entry */
export declare function getRootEntry({ filepath, _map }: FileListingSetting): Promise<ListEntryStats>;
export declare function getRootEntry({ filepath, _map, bigint }: FileListingSetting): Promise<ListEntryStatsAny>;

@@ -84,3 +84,3 @@ import fs from "node:fs/promises";

/** 100 lines of code to handle edge cases to create the root entry */
export async function getRootEntry({ filepath, _map }) {
export async function getRootEntry({ filepath, _map, bigint }) {
let dirents = [];

@@ -90,3 +90,3 @@ filepath = path.resolve(filepath);

try {
stats = await fs.lstat(filepath);
stats = await fs.lstat(filepath, { bigint });
}

@@ -93,0 +93,0 @@ catch (err) {

@@ -55,2 +55,5 @@ /// <reference types="node" />

};
export type StatEntryAny = {
stats: Stats | BigIntStats;
};
export type StatEntryError = {

@@ -61,4 +64,5 @@ errors: StatError;

export type StatEntryBaseBigInt = StatEntryBigInt | StatEntryError;
export type StatEntryBaseAny = StatEntryAny | StatEntryError;
export type ListEntryStats = StatEntryBase & ListEntryBaseEx;
export type ListEntryStatsBigInt = StatEntryBaseBigInt & ListEntryBaseEx;
export type ListEntryStatsAny = ListEntryStats | ListEntryStatsBigInt;
export type ListEntryStatsAny = StatEntryBaseAny & ListEntryBaseEx;