Wrap up return value

Return JS array instead of string to increase usability.