diff --git a/src/components/TaskItem.js b/src/components/TaskItem.js index b9dca50947d36503a5457c9310546180bb8769fe..0265ca779fe1efdea077bca5c26557726f4400c1 100644 --- a/src/components/TaskItem.js +++ b/src/components/TaskItem.js @@ -70,15 +70,11 @@ class TaskItem extends React.Component { }; render() { - let factionlistItems = []; - for (let i = 0; i < this.state.factions.length; i++) { - const faction = this.state.factions[i]; - factionlistItems.push( - <option key={faction.factionId} value={faction.factionId}> - {faction.factionName} - </option> - ); - } + let factionlistItems = this.state.factions.map(faction => ( + <option key={faction.factionId} value={faction.factionId}> + {faction.factionName} + </option> + )); return ( <div className="tasklist-item">