code refactoring
simplified configuration
improved error handling