<?php

namespace App\Models;

use CodeIgniter\Model;

class LanguageModel extends Model
{
    protected $table         = 'language';
    protected $primaryKey    = 'id';
    protected $returnType    = 'object';
    protected $allowedFields = [
        'url_extension',
        'language',
    ];

    public function getAllLanguages()
    {
        return $this->where("language !=", "")
                    ->where("language IS NOT NULL")
                    ->findAll();
    }
}
