ソースを参照

Ajout controle num page inf 1

Arthur Brandao 5 年 前
コミット
836f27ee9e
1 ファイル変更3 行追加0 行削除
  1. 3 0
      src/microfolie/entry/rest/UsagerController.java

+ 3 - 0
src/microfolie/entry/rest/UsagerController.java

@@ -42,6 +42,9 @@ public class UsagerController {
 		JSONObject data = new JSONObject();
 		// Récupération info
 		long total = service.getTotalNumber();
+		if (num < 1) {
+			num = 1;
+		}
 		while (total <= perPage * (num - 1)) {
 			num--;
 		}