From d89733f6c7ec046ed2ad3a463306b34af6863baf Mon Sep 17 00:00:00 2001 From: Sam Hemelryk Date: Mon, 5 Aug 2013 09:34:55 +1200 Subject: [PATCH] MDL-41025 moodlelib: addressed todo on truncate_userinfo --- lib/moodlelib.php | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/lib/moodlelib.php b/lib/moodlelib.php index c190a823f93..47bc1a3a87e 100644 --- a/lib/moodlelib.php +++ b/lib/moodlelib.php @@ -4111,15 +4111,12 @@ function update_user_record($username) { } /** - * Will truncate userinfo as it comes from auth_get_userinfo (from external auth) - * which may have large fields - * - * @todo Add vartype handling to ensure $info is an array + * Will truncate userinfo as it comes from auth_get_userinfo (from external auth) which may have large fields. * * @param array $info Array of user properties to truncate if needed * @return array The now truncated information that was passed in */ -function truncate_userinfo($info) { +function truncate_userinfo(array $info) { // Define the limits. $limit = array( 'username' => 100, -- 2.43.0