Open bleu0 opened 1 year ago
Thanks for giving it a try ! 😊 i think this is a good start!
The piece you are modifying is on server end so changing the messages themselves might not be not enough.
the signature is def getApplyRejection(airline : Airline, alliance : Alliance) : Option[String]
which means it expects an scala Option
. Some
for failures, and None
when it's okay, There are logic to read the result of that and determine whether the action is acception (ie no rejection), and then that would affect how the front-end reacts (gray out buttons etc)
Therefore if we want to return a list (and for both success and failures), we will have to:
Instead of showing a Cannot Join Alliance error for applying to other alliances if you're already in one, show the following checklist:
✅ Not in another alliance | ❌ In another alliance. Leave My First Alliance first before applying. ✅ No overlapping bases | ❌ Following bases overlap: JFK JFK. Remove overlapping bases first before applying. ✅ Alliance has open spots | ❌ Alliance is full. Remove an existing member first before applying.