def get_next_and_prev(net):
    """Returns what the next and prev querystrings should be."""
    if net == 0:
        nxt = prev = 1
    elif net > 0:
        nxt = net + 1
        prev = -(net - 1)
    else:
        nxt = net + 1
        prev = abs(net) + 1
    return nxt, prev
Returns what the next and prev querystrings should be.