Tappable.php 395 B

1234567891011121314151617
  1. <?php
  2. namespace Illuminate\Support\Traits;
  3. trait Tappable
  4. {
  5. /**
  6. * Call the given Closure with this instance then return the instance.
  7. *
  8. * @param (callable($this): mixed)|null $callback
  9. * @return ($callback is null ? \Illuminate\Support\HigherOrderTapProxy : $this)
  10. */
  11. public function tap($callback = null)
  12. {
  13. return tap($this, $callback);
  14. }
  15. }