Apex’s AuthUser get_profile() problem

After reviewing apex’s code I noticed a flaw in its models. The AuthUser model has a function named get_profile, similar to Django’s auth get_profile, this function returns a user’s profile. This function was formally a classmethod, where the signed in user could only access their profile.

Sadly, this code couldn’t have been used on any social site currently in production. The code has been fixed to be an instancemethod function, and now any use of the AuthUser model can access the get_profile function. This fix was pushed in commit e94e63fcfe6495163517e164b9ac5f017e1fe7d4

Tags:

Leave a Reply