refactored and removed redundant tests inside function deepMatchType under lib/match.js