Skip to content

Commit 3db180f

Browse files
Fix issue where converting a model to an array didn't include the correct boolean field values
1 parent 909062e commit 3db180f

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ Updates should follow the [Keep a CHANGELOG](http://keepachangelog.com/) princip
1010

1111
- Removed `$booleanDates` trait variable to resolve conflict with the model it's used in
1212
- Always return a valid array when retrieving all boolean dates
13+
- Fixed issue where converting a model to an array didn't include the correct boolean field values
1314

1415
## 0.2.1 (2018-07-26)
1516

src/BooleanDates.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ protected function addBooleanDateAttributesToArray(array $attributes) : array
163163
continue;
164164
}
165165

166-
$attributes[$booleanField] = $date !== null;
166+
$attributes[$booleanField] = $this->getBooleanDate($booleanField);
167167
}
168168

169169
return $attributes;

0 commit comments

Comments
 (0)