mirror of
https://gh.catmak.name/https://github.com/mihomo-party-org/mihomo-party
synced 2026-02-10 11:40:28 +08:00
fix: correct sidecar directory lookup path
This commit is contained in:
parent
52cefa39d3
commit
19ff003352
@ -46,10 +46,10 @@ function getBindingName() {
|
||||
function loadBinding() {
|
||||
const bindingName = getBindingName()
|
||||
|
||||
// 查找项目根目录的 extra/sidecar
|
||||
// 查找项目根目录的 sidecar
|
||||
let currentDir = __dirname
|
||||
while (currentDir !== require('path').dirname(currentDir)) {
|
||||
const sidecarPath = join(currentDir, 'extra', 'sidecar', bindingName)
|
||||
const sidecarPath = join(currentDir, 'sidecar', bindingName)
|
||||
if (existsSync(sidecarPath)) {
|
||||
try {
|
||||
nativeBinding = require(sidecarPath)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user