Fixed bug in removing index.html's from pagination URLs