Sorry, don't have access to the vbulletin source code right now.
Does autoPopulatePreviewImage actually return the array? Or does it use it internally?
If you want to see what's in the variable, you can use:
Code:
{vb:debugvardump thumbnail}
--------------- Added [DATE]1410389539[/DATE] at [TIME]1410389539[/TIME] ---------------
$data isn't returned from the function, so you can't use it to do what you want it to do.