Do not overwrite $options parameter. #1113

The reason for #1113 was that $options was being overwritten by something else, which had two effects

- the options were never passed to the nextprevious call (which may have affected #1108)
- PHP Notice about array to string conversion