src/Project/Project.vala
authorAlan Knowles <alan@roojs.com>
Sun, 28 Jan 2024 05:16:43 +0000 (13:16 +0800)
committerAlan Knowles <alan@roojs.com>
Sun, 28 Jan 2024 05:16:43 +0000 (13:16 +0800)
src/Project/Project.vala

index e0cd0cb..af0e90a 100644 (file)
@@ -1002,9 +1002,9 @@ namespace Project {
                public void addError(JsRender.JsRender f, Lsp.Diagnostic diag)
                {
                        var new_ce = new Palete.CompileError.new_from_diagnostic(f, diag);
-                       var ls = this.getErrors(ce.category); // will create if necessary..
+                       var ls = this.getErrors(new_ce.category); // will create if necessary..
                        // find the file in the list store.
-                       GLib.ListStore? file_ce = 0;
+
                        for(var i =0; i < ls.get_n_items(); i++) {
                                var ce = ls.get_item(i) as Palete.CompileError;
                                if (ce.file.path == f.path) {
@@ -1014,9 +1014,9 @@ namespace Project {
                        }
                        // we did not have the file..
                        var add = new Palete.CompileError.new_from_file(f, diag.category);
+                       ls.append(add);
                        add.lines.append(ce);
-                        
-               
+                         
                }
                
                public void updateErrorsforFile(JsRender.JsRender? f)