feat(build): make permissions checks less strict

This commit is contained in:
2026-07-29 22:27:03 +02:00
parent 100adb40e9
commit 4c016bbc38
3 changed files with 13 additions and 35 deletions
-10
View File
@@ -16,16 +16,6 @@ limitations under the License.
import { access, constants, stat } from 'node:fs/promises';
export const checkFileReadAccess = async function checkFileWriteAccess (path) {
try {
await access(path, constants.F_OK | constants.R_OK);
return true;
} catch (err) {
if (err.code === 'ENOENT' || err.code === 'EACCES') return false;
else throw err;
}
};
export const exists = async function exists (path) {
try {
await access(path, constants.F_OK);