Filter Sent Items correctly

Fix #2. Was using an "is_array" test rather than an "is_object",
hence nothing being filtered. Also sped up the code by collapsing
the separate "run on Inbox/run on Sent Items" foreach loops into
a single foreach loop that runs both tasks serially. Left in some
better logging, it makes checking that Filter runs have worked
easier.