PHP code example of uogsoe / hash-model-id

1. Go to this page and download the library: Download uogsoe/hash-model-id library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

uogsoe / hash-model-id example snippets


// app/Exceptions/Handler.php

    public function report(Exception $exception)
    {
        if (Auth::check() && $this->shouldReport($exception)) {
            $user = Auth::user();
            \Log::error($exception->getMessage(), [
                'person' => ['id' => $user->id_hash]
            ]);
        }
        parent::report($exception);
    }