Make aurjson error messages consistent

Message ID 20170214191711.30010-1-straubem@gmx.de
State Accepted, archived
Headers show

Commit Message

Michael Straube Feb. 14, 2017, 7:17 p.m. UTC
All error messages in aurjson except two end with a period.
Add the missing periods to make the messages consistent.

Signed-off-by: Michael Straube <straubem@gmx.de>
---
 web/lib/aurjson.class.php | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Lukas Fleischer Feb. 14, 2017, 7:42 p.m. UTC | #1
On Tue, 14 Feb 2017 at 20:17:11, Michael Straube wrote:
> All error messages in aurjson except two end with a period.
> Add the missing periods to make the messages consistent.
> 
> Signed-off-by: Michael Straube <straubem@gmx.de>
> ---
>  web/lib/aurjson.class.php | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> [...]

Applied, thanks!

Patch

diff --git a/web/lib/aurjson.class.php b/web/lib/aurjson.class.php
index 3bd9179..e07522d 100644
--- a/web/lib/aurjson.class.php
+++ b/web/lib/aurjson.class.php
@@ -387,7 +387,7 @@  class AurJSON {
 
 		if ($search_by === 'name' || $search_by === 'name-desc') {
 			if (strlen($keyword_string) < 2) {
-				return $this->json_error('Query arg too small');
+				return $this->json_error('Query arg too small.');
 			}
 			$keyword_string = $this->dbh->quote("%" . addcslashes($keyword_string, '%_') . "%");
 
@@ -441,7 +441,7 @@  class AurJSON {
 		$names = $args['names'];
 
 		if (!$ids && !$names) {
-			return $this->json_error('Invalid query arguments');
+			return $this->json_error('Invalid query arguments.');
 		}
 
 		$where_condition = "";