resolved map compilation error + minor code fixes