Skip to content
This repository was archived by the owner on Jun 22, 2025. It is now read-only.

Commit 3bb6f80

Browse files
authored
Merge pull request #126 from ChrisKnott/shw-none-concat
Check if using templating before concat
2 parents 5e551f3 + 0e1fd6a commit 3bb6f80

File tree

3 files changed

+11
-7
lines changed

3 files changed

+11
-7
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# Change log
22

3+
### v0.10.3
4+
* Fix a bug that prevented using Eel without Jinja templating.
5+
36
### v0.10.2
47
* Only render templates from within the declared jinja template directory.
58

eel/__init__.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -153,12 +153,13 @@ def _eel():
153153

154154
@btl.route('/<path:path>')
155155
def _static(path):
156-
template_prefix = _jinja_templates + '/'
156+
if _jinja_templates is not None:
157+
template_prefix = _jinja_templates + '/'
157158

158-
if _jinja_env != None and path.startswith(template_prefix):
159-
n = len(template_prefix)
160-
template = _jinja_env.get_template(path[n:])
161-
return template.render()
159+
if _jinja_env is not None and path.startswith(template_prefix):
160+
n = len(template_prefix)
161+
template = _jinja_env.get_template(path[n:])
162+
return template.render()
162163

163164
return btl.static_file(path, root=root_path)
164165

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
setup(
55
name='Eel',
6-
version='0.10.2',
6+
version='0.10.3',
77
author='Chris Knott',
88
author_email='chrisknott@hotmail.co.uk',
99
packages=['eel'],
@@ -13,7 +13,7 @@
1313
install_requires=['bottle', 'bottle-websocket', 'future', 'whichcraft'],
1414
python_requires='>=2.6',
1515
description='For little HTML GUI applications, with easy Python/JS interop',
16-
long_description=open('README.md', encoding='utf-8').readlines()[1],
16+
long_description=open('README.md', encoding='utf-8').read(),
1717
keywords=['gui', 'html', 'javascript', 'electron'],
1818
homepage='https://github.com/ChrisKnott/Eel',
1919
)

0 commit comments

Comments
 (0)