Fixing some errors on mapping