added bamboo check before exiting