New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add feed-related commands #88
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thing to take note for further implementation:
- What will happen if the URL provided is inaccurate?
private void fetchPosts(ObservableList<FeedPost> feedPostList, List<Feed> feedList) { | ||
Runnable feedPostFetch = () -> { | ||
for (Feed feed : feedList.getFeedList()) { | ||
for (Feed feed : feedList) { | ||
ObservableList<FeedPost> feedPosts = feed.fetchPosts(); | ||
Platform.runLater(() -> { | ||
feedPostList.addAll(feedPosts); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if the URL provided is not accurate? What will be the response given by the application?
String name = ParserUtil.parseName(argMultimap.getValue(PREFIX_NAME).get()).fullName; | ||
String address = ParserUtil.parseAddress(argMultimap.getValue(PREFIX_ADDRESS).get()).value; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will it be a huge hurdle to build a validation check before adding into the list? Personally believe that if the URL is wrong, then the application should not save it into the list in the first place.
addfeed
anddeletefeed
commands