add defined type for excludes and some refactoring
3 files changed