|
|
|
@ -72,5 +72,5 @@ def resolve_hash(hash):
@@ -72,5 +72,5 @@ def resolve_hash(hash):
|
|
|
|
|
db.session.commit() |
|
|
|
|
|
|
|
|
|
countermessage = "" if url.view_counter is None else f". View counter was lowered to {url.view_counter}" |
|
|
|
|
app.logger.info(f"{request.environ['REMOTE_ADDR']} requested hash '{url.hash}' which resolved to '{url.url}'{countermessage}") |
|
|
|
|
app.logger.info(f"{request.environ['HTTP_X_FORWARDED_FOR']} requested hash '{url.hash}' which resolved to '{url.url}'{countermessage}") |
|
|
|
|
return redirect(url.url, 301) |
|
|
|
|