refactoring rssread to use flag package