remove use of fileProviderOf in compiler UI

pull/5370/head
yann300 3 years ago committed by davidzagi93@gmail.com
parent 1a38fd9160
commit ef4342e13b
  1. 9
      libs/remix-ui/renderer/src/lib/renderer.tsx

@ -86,17 +86,12 @@ export const Renderer = ({ message, opt = {}, plugin }: RendererProps) => {
setClose(true)
}
const _errorClick = (errFile, errLine, errCol) => {
const _errorClick = async (errFile, errLine, errCol) => {
if (errFile !== plugin.getAppParameter('currentFile')) {
// TODO: refactor with this._components.contextView.jumpTo
const provider = plugin.fileProviderOf(errFile)
if (provider) {
provider.exists(errFile).then(() => {
if (await plugin.fileExists(errFile)) {
plugin.open(errFile)
plugin.call('editor', 'gotoLine', errLine, errCol)
}).catch(error => {
if (error) return console.log(error)
})
}
} else {
plugin.call('editor', 'gotoLine', errLine, errCol)

Loading…
Cancel
Save