Added configuration options
Clean-ep and removal of broken code