make logic usable for any pod

this rearranges code a bit so that users can examine their own pods