Skip to content

Commit

Permalink
core: fix #135 type conversion in quickSell & watchlistDelete
Browse files Browse the repository at this point in the history
  • Loading branch information
oczkers committed Feb 11, 2015
1 parent ea95ac3 commit bcf6683
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions AUTHORS.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,4 @@ Patches and Suggestions
- Innursery
- Arthur Nogueira Neves @arthurnn
- jamslater
- rjansen
4 changes: 2 additions & 2 deletions fut/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -525,7 +525,7 @@ def sell(self, item_id, bid, buy_now=0, duration=3600):
def quickSell(self, item_id):
"""Quick sell."""
if not isinstance(item_id, (list, tuple)):
item_id = (item_id)
item_id = (item_id,)
item_id = (str(i) for i in item_id)
params = {'itemIds': ','.join(item_id)}
self.__delete__(self.urls['fut']['Item'], params=params) # returns nothing
Expand All @@ -534,7 +534,7 @@ def quickSell(self, item_id):
def watchlistDelete(self, trade_id):
"""Removes cards from watchlist."""
if not isinstance(trade_id, (list, tuple)):
trade_id = (trade_id)
trade_id = (trade_id,)
trade_id = (str(i) for i in trade_id)
params = {'tradeId': ','.join(trade_id)}
self.__delete__(self.urls['fut']['WatchList'], params=params) # returns nothing
Expand Down

0 comments on commit bcf6683

Please sign in to comment.