fixed bug - leftLimit was set to a negative value