refactor(constant): Screaming camel MAX_LEVEL
This commit is contained in:
@@ -4,11 +4,11 @@
|
||||
------------------------------------------------------
|
||||
*/
|
||||
|
||||
export const maxLevel = 100;
|
||||
export const MAX_LEVEL = 100;
|
||||
|
||||
export function capByLevel (lvl) {
|
||||
if (lvl > maxLevel) {
|
||||
return maxLevel;
|
||||
if (lvl > MAX_LEVEL) {
|
||||
return MAX_LEVEL;
|
||||
} else {
|
||||
return lvl;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user