Open nurzhanme opened 1 year ago
This is the designed behavior. You can’t add cards to a pile until you have first drawn them from the deck.
On Sun, Apr 9, 2023 at 4:27 PM Nurzhan Aitbayev @.***> wrote:
Adding to Piles method returns the same deck as it was before, even though deck contains cards I want to draw and add to pile
Steps to reproduce:
[image: 1] https://user-images.githubusercontent.com/4818097/230799389-cbf5b832-7391-4c4a-9055-3145ca7d43de.png
- Take deck_id and put to https://deckofcardsapi.com/api/deck/ <
>/pile/p1/add/?cards=AS,2S [image: 2] https://user-images.githubusercontent.com/4818097/230799390-2677c28c-b0a5-4297-9d15-c68aad36d20d.png
- Then call https://deckofcardsapi.com/api/deck/<
>/pile/p1/list/ [image: 3] https://user-images.githubusercontent.com/4818097/230799391-ad080a65-cdeb-4574-b55d-b5186299f96a.png
And deck still has 52 cards and pile player1 is empty
— Reply to this email directly, view it on GitHub https://github.com/crobertsbmw/deckofcards/issues/130, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABMQLHSU4YV4QAJ7RDPFQXTXAMZWPANCNFSM6AAAAAAWYLUK2E . You are receiving this because you are subscribed to this thread.Message ID: @.***>
--
Chase Roberts
Computer Engineering for Babies https://computerengineeringforbabies.com/
https://computerengineeringforbabies.com @.***> https://www.instagram.com/ce_for_babies/ https://twitter.com/crobertsbmw https://www.linkedin.com/in/chase-roberts-22b28128/
Adding to Piles method returns the same deck as it was before, even though deck contains cards I want to draw and add to pile
Steps to reproduce:
Call
https://deckofcardsapi.com/api/deck/new/shuffle/
Take
deck_id
and put tohttps://deckofcardsapi.com/api/deck/<<deck_id>>/pile/p1/add/?cards=AS,2S
Then call
https://deckofcardsapi.com/api/deck/<<deck_id>>/pile/p1/list/
And deck still has 52 cards and pile
p1
is empty