Adjust control structure in CharmBoard::Controller::Auth
#1
Labels
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: nu/CharmBoard#1
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The control structure here sucks. It sucked to write, it sucks to read, and I guarantee that if left alone, it'll suck to make minor changes to later on.
I had it suggested to me to try maybe switch statements, and I also saw that suggested elsewhere as a way to improve upon nested if/else control structure. I'll need to look into that and some other things more though as I'm not super familiar with the options here atm
And now with commit
07977292fe
I've fixed this specifically forlogin_do
, but I used a try/catch control structure instead of given/when. Still unsure what I should be doing forregister_do
however, because it's complex enough that I don't think I can do one big try/catchAs of commit
f0ab7713cc
, bothlogin_do
andregister_do
use two try/catch blocks each, making this problem solved!