diff --git a/CHANGELOG.md b/CHANGELOG.md index 65cae9e..db7fbb3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,3 +21,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Removed - Nothing + +## [1.0.1] - 2021-07-29 +### Bug Fixes +- Country: fixed typo on callingcode column name. +- CityLocale: Added check for empty Division Name in the display function as it was giving errors when it was null. diff --git a/src/CityLocale.php b/src/CityLocale.php index 0f46f64..ffbb3c5 100644 --- a/src/CityLocale.php +++ b/src/CityLocale.php @@ -73,7 +73,7 @@ public function fields(Request $request) return $request->isUpdateOrUpdateAttachedRequest(); }) ->display(function($someModel){ - if ($someModel->country->has_division) + if ($someModel->country->has_division && !empty($someModel->division->name)) return $someModel->name.', ' . $someModel->division->name . ', '. $someModel->country->name; else return $someModel->name.', ' . $someModel->country->name; diff --git a/src/Country.php b/src/Country.php index dc905d4..556a909 100644 --- a/src/Country.php +++ b/src/Country.php @@ -109,7 +109,7 @@ public function fields(Request $request) ->hideFromIndex() ->nullable() ->rules( 'max:8'), - Text::make(__('Calling Prefix'), 'Callingcode') + Text::make(__('Calling Prefix'), 'callingcode') ->sortable() ->nullable() ->hideFromIndex()