Fix undeclared variable in TEMPLATE_PAGINATION

This change fixes a silly mistake in my previous checkin adding
the TEMPLATE_PAGINATION setting.