Including django authentication
Renamed functions for beter purpose