{"size": 343, "ext": "js", "max_stars_repo_path": "server/src/eventHandlers/storyRestored.js", "max_stars_repo_name": "sthagen/Zuehlke-poinz", "max_stars_repo_stars_event_min_datetime": "2016-03-20T20:17:38.000Z", "max_stars_repo_stars_event_max_datetime": "2022-03-25T09:33:45.000Z", "max_issues_repo_path": "server/src/eventHandlers/storyRestored.js", "max_issues_repo_name": "sthagen/Zuehlke-poinz", "max_issues_repo_issues_event_min_datetime": "2016-03-05T10:43:17.000Z", "max_issues_repo_issues_event_max_datetime": "2022-03-30T09:25:21.000Z", "max_forks_repo_path": "server/src/eventHandlers/storyRestored.js", "max_forks_repo_name": "sthagen/Zuehlke-poinz", "max_forks_repo_forks_event_min_datetime": "2016-04-14T11:43:31.000Z", "max_forks_repo_forks_event_max_datetime": "2022-03-31T20:11:18.000Z"}
{"max_stars_count": 82, "max_issues_count": 128, "max_forks_count": 67, "avg_line_length": 22.8666666667, "max_line_length": 62, "alphanum_fraction": 0.6909620991}
/**
 * Resets "trashed" flag on matching story.
 * Flag will be "false" afterwards.
 */
import {modifyStory} from './roomModifiers';

const storyRestoredEventHandler = (room, eventPayload) => {
  return modifyStory(room, eventPayload.storyId, (story) => ({
    ...story,
    trashed: false
  }));
};

export default storyRestoredEventHandler;
