move plugin handling to bot class