Skip to content

Commit

Permalink
[Fixes #77] Fix pr comments
Browse files Browse the repository at this point in the history
  • Loading branch information
mattiagiupponi committed Mar 3, 2023
1 parent a1a3936 commit c3e0036
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions importer/handlers/csv/handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,9 @@ def can_handle(_data) -> bool:
if not base:
return False
return (
base.endswith(".csv")
base.lower().endswith(".csv")
if isinstance(base, str)
else base.name.endswith(".csv")
else base.name.lower().endswith(".csv")
)

@staticmethod
Expand Down Expand Up @@ -165,7 +165,7 @@ def extract_resource_to_publish(self, files, action, layer_name, alternate, **kw
return [
{
"name": alternate,
"crs": ResourceBase.objects.filter(Q(alternate__icontains=layer_name) | Q(title__icontains=layer_name))
"crs": ResourceBase.objects.filter(alternate__istartswith=layer_name)
.first()
.srid,
}
Expand Down

0 comments on commit c3e0036

Please sign in to comment.