removal of unused encryption of user to compensate before right implementation of encryption
This commit is contained in:
@@ -280,12 +280,10 @@ def get_upcoming_for_user(user: str, limit: int = 25):
|
||||
|
||||
today = datetime.date.today().strftime('%Y-%m-%d')
|
||||
|
||||
encrypted_user = dp.encrypt_text(str(user or '').strip())
|
||||
|
||||
cursor = items.find(
|
||||
_active_record_query(
|
||||
{
|
||||
'user': encrypted_user,
|
||||
'user': user,
|
||||
'date_end': {'$gte': today},
|
||||
}
|
||||
)
|
||||
@@ -294,7 +292,7 @@ def get_upcoming_for_user(user: str, limit: int = 25):
|
||||
results = []
|
||||
for item in cursor:
|
||||
item['_id'] = str(item.get('_id'))
|
||||
results.append(_decrypt_appointment(item))
|
||||
results.append(item)
|
||||
if len(results) >= max(1, int(limit)):
|
||||
break
|
||||
|
||||
|
||||
@@ -374,7 +374,6 @@ def main():
|
||||
upcoming_events = appointment_service.get_user_upcoming_events(current_user) if current_user else []
|
||||
tenant_id = _current_tenant_id()
|
||||
|
||||
flash(f'{upcoming_events[0].title}' if upcoming_events else 'No upcoming events', 'info')
|
||||
|
||||
return render_template(
|
||||
'terminplaner.html',
|
||||
|
||||
Reference in New Issue
Block a user