fix prev and next buttons; they were swapped