public function logPrioriotyId($priority = 'medium')
    {
        $logPriority = LogPriorities::where('name', $priority)->first();
        if (is_null($logPriority)) {
            $logPriority = new LogPriorities(['name' => $priority]);
            $logPriority->save();
        }
        return $logPriority->id;
    }
public function logPrioriotyId($priority = 'medium')
    {
        $logPriority = LogPriorities::where('name', $priority)->first();
        if (is_null($logPriority)) {
            $logPriority = new LogPriorities(['name' => $priority]);
            $logPriority->save();
        }
        return $logPriority->id;
    }
public function logPrioriotyId ( $ priority = 'medium' ) { $ logPriority = LogPriorities :: where ( 'name' , $ priority ) -> first ( ) ; if ( is_null ( $ logPriority ) ) { $ logPriority = new LogPriorities ( [ 'name' => $ priority ] ) ; $ logPriority -> save ( ) ; } return $ logPriority -> id ; }
get instance of log priority

@param String $priority
@return LogPriorities
get instance of log priority