Partial code structure refactor

irst this case should be unreachable, second you have check that is unproper - you just call return - if this is a some special situation - throw exception.