a4phone 1.1.3 → 1.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "a4phone",
3
- "version": "1.1.3",
3
+ "version": "1.1.4",
4
4
  "description": "Claude Code / Codex 远程手机交互:任务完成通知、AskUserQuestion 提问与 PermissionRequest 权限请求手机点选(ntfy.sh)",
5
5
  "type": "module",
6
6
  "bin": {
@@ -31,6 +31,11 @@ export async function handlePermissionRequest(input, agentName) {
31
31
  const config = loadConfig();
32
32
  if (!config.topic) return null;
33
33
 
34
+ // AskUserQuestion 的交互由 asku 处理器负责,此处直接放行,避免冗余的原始 JSON 推送
35
+ if (input.tool_name === 'AskUserQuestion') {
36
+ return { hookSpecificOutput: { hookEventName: 'PermissionRequest', decision: { behavior: 'allow' } } };
37
+ }
38
+
34
39
  const tool_name = input.tool_name || 'Unknown';
35
40
  const message = formatMessage(tool_name, input.tool_input);
36
41
  const requestId = crypto.randomUUID();