Skip to content

Commit

Permalink
add phpdoc for function
Browse files Browse the repository at this point in the history
  • Loading branch information
nerrad committed Apr 30, 2018
1 parent f895c28 commit 793503c
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,14 @@
*/
import { reduce } from 'lodash';

/**
* Receives an array of event entities and returns an array of simple objects
* that can be passed along to the options array used for the WordPress
* SelectControl component.
*
* @param { Array } events
* @return { Array }
*/
export const buildEventOptions = ( events ) => {
return reduce( events, function( options, event ) {
options.push(
Expand Down

0 comments on commit 793503c

Please sign in to comment.