Skip to content
Permalink
Browse files

Add jsonp parameter in API as a fallback to match documentation (#2567)

* Add jsonp parameter as fallback to match API documentation
* Correct alignment to match standards
Fixes #2566
  • Loading branch information...
bluemorbo authored and ozh committed Oct 14, 2019
1 parent fbba93d commit 80256f457b33beb448d31220893c16f686b93e55
Showing with 2 additions and 0 deletions.
  1. +2 −0 yourls-api.php
@@ -43,6 +43,8 @@
if( isset( $_REQUEST['callback'] ) )
$return['callback'] = $_REQUEST['callback'];
elseif ( isset( $_REQUEST['jsonp'] ) )
$return['callback'] = $_REQUEST['jsonp'];
$format = ( isset( $_REQUEST['format'] ) ? $_REQUEST['format'] : 'xml' );

0 comments on commit 80256f4

Please sign in to comment.
You can’t perform that action at this time.