alleyinteractive / byline-manager

Manage an article's byline and author profiles in WordPress.
GNU General Public License v3.0
3 stars 2 forks source link

Fix invalid use of useCallback #260

Closed mboynes closed 7 months ago

mboynes commented 7 months ago

setBylineMeta() is a higher-order function, and was previously called using,

const saveByline = setBylineMeta(dispatch, metaKey);

When we added useCallback, it inadvertently added a function layer, leading to setBylineMeta() not actually being called. This ultimately meant that bylines were not updated when saving a post.