From 44a92e37de73a62ef72f7158e148150b03f68c22 Mon Sep 17 00:00:00 2001 From: Kherin Date: Fri, 5 Jan 2024 21:46:06 +0400 Subject: [PATCH] refactor: made use of the f-string format --- project1/myapp/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project1/myapp/views.py b/project1/myapp/views.py index bf9a8c5..e5a8f56 100644 --- a/project1/myapp/views.py +++ b/project1/myapp/views.py @@ -18,7 +18,7 @@ def getform(request): if request.method == "POST": id = request.POST["id"] name = request.POST["name"] - return HttpResponse("Name: {}, Id: {}".format(name, id)) + return HttpResponse(f'Name: {name}, Id: {id}') def drinks(request, drink_name):