Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
PizzaPalace
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TheJoeCoder
PizzaPalace
Commits
9dce4969
Verified
Commit
9dce4969
authored
2 years ago
by
TheJoeCoder
Browse files
Options
Downloads
Patches
Plain Diff
[Server] Code fix and bugfixes
parent
fb71d3b5
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
server/app.py
+2
-2
2 additions, 2 deletions
server/app.py
with
2 additions
and
2 deletions
server/app.py
+
2
−
2
View file @
9dce4969
...
...
@@ -96,7 +96,7 @@ def get_cart_items():
# Get cart and verify not none
cart
=
get_cart
(
cart_id
,
cart_key
)
if
(
cart
==
None
):
return
"
{
\"
status
\"
:403,
\"
message
\"
:
\"
invalid cart credentials
\"
}
"
,
403
return
gen_invalid_creds_msg
()
return
"
{
\"
status
\"
:200,
\"
items
\"
:
"
+
json
.
dumps
(
cart
[
"
items
"
])
+
"
}
"
,
200
@app.route
(
"
/cart/add
"
,
methods
=
[
"
POST
"
])
...
...
@@ -226,7 +226,7 @@ def confirm_order_cart():
# Remove cart from existing carts
del
open_carts
[
cart_id
]
# Return order ID
return
"
{
\"
status
\"
:200,
\"
message
\"
:
\"
OK
\"
,
\"
code
\"
:
\"
"
+
str
(
order_id
)
+
"
\"
}
"
,
200
return
"
{
\"
status
\"
:200,
\"
message
\"
:
\"
ok
\"
,
\"
code
\"
:
\"
"
+
str
(
order_id
)
+
"
\"
}
"
,
200
# Main program code
if
(
__name__
==
"
__main__
"
):
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment