File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -606,7 +606,26 @@ async function loadToolApprovals() {
606606 try {
607607 const response = await api .getToolApprovals (server .value .name )
608608 if (response .success && response .data ) {
609- toolApprovals .value = response .data .tools || []
609+ const approvals = response .data .tools || []
610+
611+ // Fetch diffs for changed tools to populate previous_description
612+ const changedTools = approvals .filter (t => t .status === ' changed' )
613+ if (changedTools .length > 0 ) {
614+ const diffPromises = changedTools .map (async (tool ) => {
615+ try {
616+ const diffResp = await api .getToolDiff (server .value ! .name , tool .tool_name )
617+ if (diffResp .success && diffResp .data ) {
618+ tool .previous_description = diffResp .data .previous_description
619+ tool .current_description = diffResp .data .current_description
620+ }
621+ } catch {
622+ // Diff fetch failed, continue without it
623+ }
624+ })
625+ await Promise .all (diffPromises )
626+ }
627+
628+ toolApprovals .value = approvals
610629 }
611630 } catch {
612631 // Silently fail - tool approvals are supplementary info
You can’t perform that action at this time.
0 commit comments