fixing bugs and bad import syntax