From 888f941ae16c850c0f1a844ec9436058840920bd Mon Sep 17 00:00:00 2001
From: WXL <wl_5969728@163.com>
Date: 星期五, 24 四月 2026 09:19:02 +0800
Subject: [PATCH] 推送

---
 node_modules/tapable/lib/Hook.js |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/node_modules/tapable/lib/Hook.js b/node_modules/tapable/lib/Hook.js
index b1e9ceb..6da14b2 100644
--- a/node_modules/tapable/lib/Hook.js
+++ b/node_modules/tapable/lib/Hook.js
@@ -66,11 +66,14 @@
 	_tap(type, options, fn) {
 		if (typeof options === "string") {
 			options = {
-				name: options.trim()
+				name: options
 			};
 		} else if (typeof options !== "object" || options === null) {
 			throw new Error("Invalid tap options");
 		}
+		if (typeof options.name === "string") {
+			options.name = options.name.trim();
+		}
 		if (typeof options.name !== "string" || options.name === "") {
 			throw new Error("Missing name for tap");
 		}

--
Gitblit v1.9.3