Browse Source

greader.php: only return 'OK' on greader.php without query parameters (#6238)

It'd be clearer if the API endpoint didn't return `OK` when adding the `Email` and `Passwd` parameters. Whether it should indeed return `OK` if they're correct is debatable.

In reply to <https://github.com/FreshRSS/FreshRSS/issues/5856#issuecomment-2019814077>.
Frans de Jonge 2 years ago
parent
commit
d7f5ef3627
1 changed files with 1 additions and 1 deletions
  1. 1 1
      p/api/greader.php

+ 1 - 1
p/api/greader.php

@@ -992,7 +992,7 @@ final class GReaderAPI {
 		}
 		$pathInfo = urldecode($pathInfo);
 		$pathInfo = '' . preg_replace('%^(/api)?(/greader\.php)?%', '', $pathInfo);	//Discard common errors
-		if ($pathInfo == '') {
+		if ($pathInfo == '' && empty($_SERVER['QUERY_STRING'])) {
 			exit('OK');
 		}
 		$pathInfos = explode('/', $pathInfo);