Skip to content

Commit 258f45a

Browse files
committed
Fixed compile error
1 parent 745cf63 commit 258f45a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

handler/handler.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ func (handler *InoHandler) createFileData(ctx context.Context, sourceURI lsp.Doc
221221
return nil, nil, err
222222
}
223223
// Fallback: use the source text unchanged
224-
targetBytes, err = copyIno2Cpp([]byte(sourceText), targetPath)
224+
targetBytes, err = copyIno2Cpp(sourceText, targetPath)
225225
if err != nil {
226226
return nil, nil, err
227227
}
@@ -256,7 +256,7 @@ func (handler *InoHandler) updateFileData(data *FileData, change *lsp.TextDocume
256256
if err != nil {
257257
if rang == nil {
258258
// Fallback: use the source text unchanged
259-
targetBytes, err = copyIno2Cpp([]byte(newSourceText), uriToPath(data.targetURI))
259+
targetBytes, err = copyIno2Cpp(newSourceText, uriToPath(data.targetURI))
260260
if err != nil {
261261
return err
262262
}

0 commit comments

Comments
 (0)