Skip to main content

"Black Friday" Discount! Only until December 1st: 50% off all membership plans!

Read more here

monicahq/monica

25824 stars
3 code files
View monicahq/monica on GitHub

app/Interfaces/Hashing.php

Open in GitHub
interface Hashing
{
public function hashID();
}

app/Models/ModelBindingHasher.php

Open in GitHub
use App\Traits\Hasher;
use App\Interfaces\Hashing;
 
abstract class ModelBindingHasher extends ModelBinding implements Hashing
{
use Hasher;
}

app/Traits/Hasher.php

Open in GitHub
trait Hasher
{
//
public function hashID()
{
return $this->getRouteKey();
}
}