https://wptom.com/blog/wordpress-action-hook-when-publishing-a-post-and-custom-fields/