mirror of
https://github.com/1Panel-dev/MaxKB.git
synced 2025-12-25 17:22:55 +00:00
fix: Code editor malfunction (#4523)
This commit is contained in:
parent
38191f70b4
commit
fd7c13b7a2
|
|
@ -97,9 +97,13 @@ function getRangeFromLineAndColumn(state: any, line: number, column: number, end
|
|||
}
|
||||
}
|
||||
const asyncLint = throttle(async (view: any) => {
|
||||
const sendString = view.state.doc.toString()
|
||||
const res = await loadSharedApi({ type: 'tool', systemType: apiType.value }).postPylint(
|
||||
view.state.doc.toString(),
|
||||
)
|
||||
if (sendString !== view.state.doc.toString()) {
|
||||
return []
|
||||
}
|
||||
return res.data
|
||||
}, 500)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue