Skip to content

Commit c101cf9

Browse files
Apply suggestions from code review
Co-authored-by: Bénédikt Tran <[email protected]>
1 parent 31387a0 commit c101cf9

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Lib/linecache.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ def _getlines_from_code(code):
6464

6565

6666
def _source_unavailable(filename):
67-
"""Return True if the source code is unavailable for such file name"""
67+
"""Return True if the source code is unavailable for such file name."""
6868
return (
6969
not filename
7070
or (filename.startswith('<')
@@ -134,7 +134,7 @@ def updatecache(filename, module_globals=None):
134134
if filename.startswith('<frozen ') and module_globals is not None:
135135
# This is a frozen module, so we need to use the filename
136136
# from the module globals.
137-
fullname = module_globals.get('__file__', None)
137+
fullname = module_globals.get('__file__')
138138
if fullname is None:
139139
return []
140140
else:
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Support frozen modules for :func:`linecache.getlines()`
1+
Support frozen modules for :func:`linecache.getlines`.

0 commit comments

Comments
 (0)