fixed bug with pagesize