Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't look for an attribute on None object #4603

Conversation

gamboz
Copy link
Collaborator

@gamboz gamboz commented Jan 29, 2025

Not particularly important, but I thought I'd report 🙂

In the decorator article_stage_accepted_or_later_or_staff_required, there is an if clause that might try to access an attribute of a None object.

To replicate, one should log-in to a journal and manually enter the URL of a non existing article in order to trigger the view "article_file_download" (views.serve_article_file).

E.g. https://olh.openlibhums.org/article/id/20000/file/1234/ (ATM article 20000 does not exist).

HTH

@joemull joemull added this to the v1.8.0 Tracker milestone Feb 7, 2025
@joemull
Copy link
Member

joemull commented Feb 7, 2025

@ajrbyers @mauromsl can we add this to the 1.8 issues please?

@joemull joemull requested a review from ajrbyers February 7, 2025 09:54
@joemull joemull assigned joemull and ajrbyers and unassigned joemull Feb 7, 2025
@ajrbyers ajrbyers requested a review from joemull February 7, 2025 10:00
@ajrbyers ajrbyers assigned joemull and unassigned ajrbyers Feb 7, 2025
@joemull joemull merged commit f831a2b into openlibhums:master Feb 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants