summaryrefslogtreecommitdiff
path: root/includes/model/UserDriverLicenses_model.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/model/UserDriverLicenses_model.php')
-rw-r--r--includes/model/UserDriverLicenses_model.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/includes/model/UserDriverLicenses_model.php b/includes/model/UserDriverLicenses_model.php
index dc38368b..2c251d66 100644
--- a/includes/model/UserDriverLicenses_model.php
+++ b/includes/model/UserDriverLicenses_model.php
@@ -45,10 +45,12 @@ function UserDriverLicense_valid($user_driver_license)
*/
function UserDriverLicense($user_id)
{
- return DB::selectOne('
+ $driverLicense = DB::selectOne('
SELECT *
FROM `UserDriverLicenses`
WHERE `user_id`=?', [$user_id]);
+
+ return empty($driverLicense) ? null : $driverLicense;
}
/**