Removed unused imports + fixed onCommand's checking for instance of Player