Don't pass function return value to array_pop()

This causes pass-by-reference errors on E_STRICT
Fixes recursion problem that was DOSing the DPLA API

In get_random_items_for_post(), I was checking for a bunch of necessary
fields, and attempting to requery if any of the checks failed. But the
logic for the requerying was failed, so that the query was taking place
but not being returned and recognized. This resulted in massive
recursion, and DOSing of the DPLA API.