Skip to content

Commit

Permalink
Return null instead of empty array
Browse files Browse the repository at this point in the history
  • Loading branch information
skoppe authored and Geod24 committed Oct 15, 2022
1 parent 8e2b94c commit cfb6f23
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion source/dub/packagesuppliers/maven.d
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ class MavenRegistryPackageSupplier : PackageSupplier {
// This enables retrival of dub packages on dub run
auto md = getMetadata(query);
if (md.type == Json.Type.null_)
return [];
return null;
auto json = getBestPackage(md, query, Dependency.any, true);
return [SearchResult(json["name"].opt!string, "", json["version"].opt!string)];
}
Expand Down

0 comments on commit cfb6f23

Please sign in to comment.