Rename function and take user instead of uid.