Fixed some compatibility issues on the manage script