diff --git a/app/admin_service.py b/app/admin_service.py index bd529a9..7f41dd5 100644 --- a/app/admin_service.py +++ b/app/admin_service.py @@ -65,7 +65,7 @@ def article(): _page_size = min(max(1, int(request.args.get("size", 5))), _article_number) # 最小的size是1 _cur_page = min(max(1, int(request.args.get("page", 1))), _article_number // _page_size + (_article_number % _page_size > 0)) # 最小的page是1 except ValueError: - return "page parameters must be int!" + return "page parameters must be integer!" _articles = get_page_articles(_cur_page, _page_size) _make_title_and_content(_articles) @@ -83,7 +83,7 @@ def article(): try: delete_id = int(request.args.get("delete_id", 0)) except: - return "Delete article ID must be int!" + return "Delete article ID must be integer!" if delete_id: # delete article delete_article_by_id(delete_id) _update_context()