Closed SilverStrings024 closed 4 years ago
I made a function in my tools file (Holds all tools to make my life easier) called get_sessions() that gets and/or sets a session key called 'track'. Inside of the "_should_track()" function in the "VisitorTrackingMiddleware" I did a check (using check_sessions() ) to ensure the key exists after the check for sessions install and before any other checks, if so I would return True or False depending on its status, if it's not in session data (return of the function would be None in this case) then it would automatically set it.
Should I make a pull request? It's not a big change and can be easily expanded to use cookies or sessions and the check_session() function can be used to get, set, or delete a cookie or session whether it connects to tracking or not. It can even be used to include some javascript/ajax to make its own accept/reject banners.
I need to give the user the ability to not be tracked but can't seem to find a way to exclude them from the tracker. Is there a way to do this or should I try to modify the package to do so? If I do get it to be able to exclude users, should I submit a PR? This is a very useful package and I'd like to help improve it if I can.