Skip to content

Commit c3e06aa

Browse files
committed
General code cleanup
1 parent c4cf959 commit c3e06aa

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

packet/context_processors.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
"""
2-
The context processors used by the jinja templates
2+
Context processors used by the jinja templates
33
"""
4+
45
from functools import lru_cache
56
from datetime import datetime
67

78
from packet.ldap import ldap_get_member
89
from packet.models import Freshman
910
from packet import app
1011

11-
1212
# pylint: disable=bare-except
1313
@lru_cache(maxsize=128)
1414
def get_csh_name(username):
@@ -18,7 +18,6 @@ def get_csh_name(username):
1818
except:
1919
return username
2020

21-
2221
# pylint: disable=bare-except
2322
@lru_cache(maxsize=128)
2423
def get_rit_name(username):
@@ -36,4 +35,4 @@ def log_time(label):
3635

3736
@app.context_processor
3837
def utility_processor():
39-
return dict(get_csh_name=get_csh_name, get_rit_name=get_rit_name, log_time=log_time)
38+
return dict(get_csh_name=get_csh_name, get_rit_name=get_rit_name, log_time=log_time)

packet/debug_utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
"""
2-
Functions for use when debugging
2+
General utilities for use when debugging
33
"""
44

55
from functools import wraps
@@ -29,4 +29,4 @@ def log_cache():
2929
Utility call for logging cache info
3030
"""
3131
print("get_csh_name():", context_processors.get_csh_name.cache_info())
32-
print("get_rit_name():", context_processors.get_rit_name.cache_info())
32+
print("get_rit_name():", context_processors.get_rit_name.cache_info())

0 commit comments

Comments
 (0)