Skip to content

Commit

Permalink
Merge pull request #80 from rubic/develop
Browse files Browse the repository at this point in the history
fix collections deprecation warning, issue #79
  • Loading branch information
bashu committed Sep 20, 2020
2 parents 61ad4b1 + 4b3cccc commit 69a082f
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions easy_maps/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@

import sys
import logging
import collections
try:
from collections.abc import Callable
except ImportError:
from collections import Callable
from datetime import timedelta

from django.db import models
Expand Down Expand Up @@ -62,7 +65,7 @@ def fetch(self):

func = getattr(settings, 'EASY_MAPS_GEOCODE', None)
if func is not None:
if not isinstance(func, collections.Callable):
if not isinstance(func, Callable):
func = importpath(func)

try:
Expand Down

0 comments on commit 69a082f

Please sign in to comment.