Skip to content

Commit

Permalink
Merge pull request #4 from TaylorSMarks/patch-1
Browse files Browse the repository at this point in the history
#3: Fixes incorrect slashes on Windows.
  • Loading branch information
christianwgd authored Jun 1, 2021
2 parents a6f7529 + e22f0d6 commit 12dbe3e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
8 changes: 2 additions & 6 deletions django_bootstrap_icons/templatetags/bootstrap_icons.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,7 @@ def bs_icon(icon_name, size=None, color=None, extra_classes=None):
'BS_ICONS_BASE_URL',
'https://cdn.jsdelivr.net/npm/[email protected]/',
)
icon_path = os.path.join(
base_url, 'icons', '.'.join((icon_name, 'svg'))
)
icon_path = f'{base_url}icons/{icon_name}.svg'
resp = requests.get(icon_path)
if resp.status_code >= 400:
return f"Icon <{icon_path}> does not exist"
Expand All @@ -127,9 +125,7 @@ def md_icon(icon_name, size=None, color=None, extra_classes=None):
'MD_ICONS_BASE_URL',
'https://cdn.jsdelivr.net/npm/@mdi/[email protected]/'
)
icon_path = os.path.join(
base_url, 'svg', '.'.join((icon_name, 'svg'))
)
icon_path = f'{base_url}svg/{icon_name}.svg'
resp = requests.get(icon_path)
if resp.status_code >= 400:
return f"Icon <{icon_path}> does not exist"
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

setuptools.setup(
name='django-bootstrap-icons',
version='0.6.0',
version='0.6.1',
packages=setuptools.find_packages(),
include_package_data=True,
description='A quick way to add Bootstrap Icons with Django template tags.',
Expand Down

0 comments on commit 12dbe3e

Please sign in to comment.