Skip to content

Instantly share code, notes, and snippets.

@bhaidar
Forked from JordanDalton/helpers.php
Created February 19, 2023 20:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bhaidar/ecddf770671d0264f725992841ca015d to your computer and use it in GitHub Desktop.
Save bhaidar/ecddf770671d0264f725992841ca015d to your computer and use it in GitHub Desktop.
Pipeline Helper / Wrapper
<?php
if( ! function_exists('pipe')) {
function pipe($payload, $steps = [])
{
return app(\Illuminate\Pipeline\Pipeline::class)
->send($payload)
->through($steps)
->thenReturn();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment