refactor($parse): improve readability on conditional assignment

Use logical OR operator instead of if statement

Closes #5065