Fixed feed refresh bug. Code reorg.