From 49bf9f8b5b4f2a2245f513d1ae19aad3b4a3db27 Mon Sep 17 00:00:00 2001 From: snipe Date: Tue, 21 Jun 2016 11:06:53 -0700 Subject: [PATCH] Switch null to lowercase for code style adherence --- app/Console/Commands/AssetImportCommand.php | 4 ++-- app/Console/Commands/LicenseImportCommand.php | 8 ++++---- app/Console/Commands/ObjectImportCommand.php | 12 ++++++------ 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/app/Console/Commands/AssetImportCommand.php b/app/Console/Commands/AssetImportCommand.php index 3af8d142b1..103a5226cf 100644 --- a/app/Console/Commands/AssetImportCommand.php +++ b/app/Console/Commands/AssetImportCommand.php @@ -396,7 +396,7 @@ class AssetImportCommand extends Command { if ($user_asset_purchase_date!='') { $asset->purchase_date = $user_asset_purchase_date; } else { - $asset->purchase_date = NULL; + $asset->purchase_date = null; } if ($user_asset_purchase_cost!='') { $asset->purchase_cost = ParseFloat(e($user_asset_purchase_cost)); @@ -414,7 +414,7 @@ class AssetImportCommand extends Command { if ($user_asset_purchase_date!='') { $asset->purchase_date = $user_asset_purchase_date; } else { - $asset->purchase_date = NULL; + $asset->purchase_date = null; } $asset->notes = e($user_asset_notes); diff --git a/app/Console/Commands/LicenseImportCommand.php b/app/Console/Commands/LicenseImportCommand.php index 7b582d93a6..0171b6c9c8 100644 --- a/app/Console/Commands/LicenseImportCommand.php +++ b/app/Console/Commands/LicenseImportCommand.php @@ -266,7 +266,7 @@ class LicenseImportCommand extends Command { } } else { $user = new User; - $user->user_id = NULL; + $user->user_id = null; } @@ -293,7 +293,7 @@ class LicenseImportCommand extends Command { if ($user_license_purchase_date!='') { $license->purchase_date = $user_license_purchase_date; } else { - $license->purchase_date = NULL; + $license->purchase_date = null; } $license->serial = e($user_license_serial); $license->seats = e($user_license_seats); @@ -302,7 +302,7 @@ class LicenseImportCommand extends Command { if ($user_license_purchase_date!='') { $license->purchase_date = $user_license_purchase_date; } else { - $license->purchase_date = NULL; + $license->purchase_date = null; } $license->license_name = $user_licensed_to_name; $license->license_email = $user_licensed_to_email; @@ -323,7 +323,7 @@ class LicenseImportCommand extends Command { if ($x==0) { $license_seat->assigned_to = $user->id; } else { - $license_seat->assigned_to = NULL; + $license_seat->assigned_to = null; } if ($license_seat->save()) { diff --git a/app/Console/Commands/ObjectImportCommand.php b/app/Console/Commands/ObjectImportCommand.php index 7661087577..25fceee72d 100644 --- a/app/Console/Commands/ObjectImportCommand.php +++ b/app/Console/Commands/ObjectImportCommand.php @@ -82,7 +82,7 @@ class ObjectImportCommand extends Command { $csv = Reader::createFromPath($this->argument('filename')); $csv->setNewline("\r\n"); $results = $csv->fetchAssoc(); - $newarray = NULL; + $newarray = null; foreach ($results as $index => $arraytoNormalize) { @@ -103,7 +103,7 @@ class ObjectImportCommand extends Command { $this->accessories = Accessory::All(['name']); $this->consumables = Consumable::All(['name']); $this->customfields = CustomField::All(['name']); - $bar = NULL; + $bar = null; if(!$this->option('web-importer')) { $bar = $this->output->createProgressBar(count($newarray)); } @@ -716,7 +716,7 @@ class ObjectImportCommand extends Command { $asset_image = $this->array_smart_fetch($row, "image"); $asset_warranty_months = intval($this->array_smart_fetch($row, "warranty months")); if(empty($asset_warranty_months)) { - $asset_warranty_months = NULL; + $asset_warranty_months = null; } // Check for the asset model match and create it if it doesn't exist $asset_model = $this->createOrFetchAssetModel($row, $item["category"], $item["manufacturer"]); @@ -751,7 +751,7 @@ class ObjectImportCommand extends Command { if ($item["purchase_date"] != '') { $asset->purchase_date = $item["purchase_date"]; } else { - $asset->purchase_date = NULL; + $asset->purchase_date = null; } if( array_key_exists('custom_fields', $item)) { @@ -828,7 +828,7 @@ class ObjectImportCommand extends Command { if (!empty($item["purchase_date"])) { $accessory->purchase_date = $item["purchase_date"]; } else { - $accessory->purchase_date = NULL; + $accessory->purchase_date = null; } if (!empty($item["purchase_cost"])) { $accessory->purchase_cost = number_format(e($item["purchase_cost"]),2); @@ -894,7 +894,7 @@ class ObjectImportCommand extends Command { if(!empty($item["purchase_date"])) { $consumable->purchase_date = $item["purchase_date"]; } else { - $consumable->purchase_date = NULL; + $consumable->purchase_date = null; } if(!empty($item["purchase_cost"])) {