Check if path_info is empty as well, fixes bug oc-632. Thanks to die3lustigen2.

This commit is contained in:
Michael Gapczynski 2012-05-13 15:26:05 -04:00
parent 6b6477a90a
commit a332c39472

View file

@ -73,7 +73,7 @@ class OC_JSON{
* Encode and print $data in json format
*/
public static function encodedPrint($data,$setContentType=true){
if(!isset($_SERVER['PATH_INFO'])) {
if(!isset($_SERVER['PATH_INFO']) || $_SERVER['PATH_INFO'] == '') {
if($setContentType){
self::setContentTypeHeader();
}