Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
UCC
uccportal
Commits
9fc650e8
Commit
9fc650e8
authored
Jan 30, 2019
by
frekk
Browse files
fix dispense get_item_price
parent
7665aac4
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/squarepay/dispense.py
View file @
9fc650e8
...
...
@@ -18,8 +18,8 @@ def run_dispense(*args):
if
DISPENSE_BIN
is
None
:
return
None
cmd
=
[
DISPENSE_BIN
]
+
args
log
.
info
(
"run_dispense: "
+
cmd
)
cmd
=
(
DISPENSE_BIN
,
)
+
args
log
.
info
(
"run_dispense: "
+
str
(
cmd
)
)
try
:
# get a string containing the output of the program
res
=
subprocess
.
check_output
(
cmd
,
timeout
=
4
,
universal_newlines
=
True
)
...
...
@@ -48,4 +48,4 @@ def get_item_price(itemid):
return
None
else
:
# return the price as a number of cents
return
int
(
float
(
s
[
0
])
*
100
)
return
int
(
float
(
s
[
1
])
*
100
)
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment