fix(rpc): remove dead RPCStateRaw branch

This commit is contained in:
2026-09-28 02:05:40 +01:00
parent 50b96eeb80
commit 79fe874c90
+2 -6
View File
@@ -6,7 +6,6 @@ import {
RPCEvents,
type RPCConfig,
type RPCState,
type RPCStateRaw,
type RPCStateWeb,
} from '../utils/types'
import type {
@@ -157,16 +156,13 @@ export class RPCInstanceWebview extends RPCInstanceBase {
return response
}
private async _createHttpClientRequest<R>(
data: RPCStateRaw | RPCState,
): Promise<R> {
const dataRaw = typeof data === 'string' ? data : stringify(data)
private async _createHttpClientRequest<R>(data: RPCState): Promise<R> {
const options = {
method: 'post',
headers: {
'Content-Type': 'application/json; charset=UTF-8',
},
body: dataRaw,
body: stringify(data),
}
const resourceName = window?.GetParentResourceName?.() ?? 'nui-frame-app'
return fetch(