SEARCH-738 Cleaned up in code
SEARCH-738 Fixed some bugs in plugin downloading