Fatal error: Class 'UserAttributeKey' not found when trying to get user attributes by handle

Permalink
I have the following bit of code in my custom registration form:

$fn = 'akID[' . UserAttributeKey::getByHandle('first_name')->getAttributeKeyID() . '][value]';


But I am getting the error message:
Fatal error: Class 'UserAttributeKey' not found in...


I tried loading the following, thinking that one of these might contain that class...but no luck...

Loader::library('attribute/controller');
Loader::model('attribute/key');
Loader::model('attribute/value');
Loader::model('attribute/type');
Loader::model('user');

 
nicolechung replied on at Permalink Reply
Loader::model('user_attributes');
RadiantWeb replied on at Permalink Best Answer Reply
RadiantWeb
that would be:

Loader::model('attribute/categories/user');


ChadStrat
ScottC replied on at Permalink Reply
ScottC
added this as best answer, as it is the correct one :)