def json_data(self, instance, default=None):
value = self.get(instance)<EOL>if value and self.is_multi_valued():<EOL><INDENT>return map(api.get_url_info, value)<EOL><DEDENT>elif value and not self.is_multi_valued():<EOL><INDENT>return api.get_url_info(value)<EOL><DEDENT>return value or default<EOL>
Get a JSON compatible value