File tree Expand file tree Collapse file tree 1 file changed +9
-17
lines changed
Expand file tree Collapse file tree 1 file changed +9
-17
lines changed Original file line number Diff line number Diff line change @@ -119,21 +119,13 @@ let getPackage ~uri state =
119119 else
120120 match findRoot ~uri state.packagesByRoot with
121121 | None -> Error " No root directory found"
122- | Some root -> (
123- match
124- match root with
125- | `Root rootPath ->
126- Hashtbl. replace state.rootForUri uri rootPath;
127- Ok
128- (Hashtbl. find state.packagesByRoot
129- (Hashtbl. find state.rootForUri uri))
130- | `Bs rootPath -> (
131- match newBsPackage rootPath with
132- | Error e -> Error e
133- | Ok package ->
134- Hashtbl. replace state.rootForUri uri package.rootPath;
135- Hashtbl. replace state.packagesByRoot package.rootPath package;
136- Ok package)
137- with
122+ | Some (`Root rootPath ) ->
123+ Hashtbl. replace state.rootForUri uri rootPath;
124+ Ok (Hashtbl. find state.packagesByRoot (Hashtbl. find state.rootForUri uri))
125+ | Some (`Bs rootPath ) -> (
126+ match newBsPackage rootPath with
138127 | Error e -> Error e
139- | Ok package -> Ok package)
128+ | Ok package ->
129+ Hashtbl. replace state.rootForUri uri package.rootPath;
130+ Hashtbl. replace state.packagesByRoot package.rootPath package;
131+ Ok package)
You can’t perform that action at this time.
0 commit comments