Factored out GET logic

Get logic now contained in separate function, making each method call
significantly shorter. Removed Connection => close header, seems to
return answer more stable