We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Right now the MethodValidate method has a switch case with a lot of boolean logic and is difficult to read.
MethodValidate
I propose using validation functions for each case. So instead of
case ccDigits.At(4) == 4011 || ccDigits.At(6) == 431274 || ccDigits.At(6) == 438935 || ccDigits.At(6) == 451416 || ccDigits.At(6) == 457393 || ccDigits.At(4) == 4576 || ccDigits.At(6) == 457631 || ccDigits.At(6) == 457632 || ccDigits.At(6) == 504175 || ccDigits.At(6) == 627780 || ccDigits.At(6) == 636297 || ccDigits.At(6) == 636368 || ccDigits.At(6) == 636369 || (ccDigits.At(6) >= 506699 && ccDigits.At(6) <= 506778) || (ccDigits.At(6) >= 509000 && ccDigits.At(6) <= 509999) || (ccDigits.At(6) >= 650031 && ccDigits.At(6) <= 650051) || (ccDigits.At(6) >= 650035 && ccDigits.At(6) <= 650033) || (ccDigits.At(6) >= 650405 && ccDigits.At(6) <= 650439) || (ccDigits.At(6) >= 650485 && ccDigits.At(6) <= 650538) || (ccDigits.At(6) >= 650541 && ccDigits.At(6) <= 650598) || (ccDigits.At(6) >= 650700 && ccDigits.At(6) <= 650718) || (ccDigits.At(6) >= 650720 && ccDigits.At(6) <= 650727) || (ccDigits.At(6) >= 650901 && ccDigits.At(6) <= 650920) || (ccDigits.At(6) >= 651652 && ccDigits.At(6) <= 651679) || (ccDigits.At(6) >= 655000 && ccDigits.At(6) <= 655019) || (ccDigits.At(6) >= 655021 && ccDigits.At(6) <= 655021): return Company{"elo", "Elo"}, nil
It could change to
case isElo(ccDigits): return Company{"elo", "Elo"}, nil
The text was updated successfully, but these errors were encountered:
Solved on #6
Sorry, something went wrong.
No branches or pull requests
Right now the
MethodValidate
method has a switch case with a lot of boolean logic and is difficult to read.I propose using validation functions for each case. So instead of
It could change to
The text was updated successfully, but these errors were encountered: