Skip to content

Whitelist/Blacklist problem when adding django app with capital letter in name #48

Description

@WasinTh

According to this issue, the code convert whitelist/blacklist to lowercase. But it'll cause another problem for capital letter django app because all the text in self.content_type_whitelist is in lowercase but the code in method genericadmin_js_init() which loop through all content type doesn't convert the app into lower case therefore the whitelist will ignore all capital letter Django App.
Here is a simple solution for this issue
In the method "genericadmin_js_init()" just add ".lower()" to these 2 lines
if val.lower() in self.content_type_whitelist:
and
elif val.lower() not in self.content_type_blacklist:

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions