@@ 136-150 (lines=15) @@ | ||
133 | * |
|
134 | * @return array |
|
135 | */ |
|
136 | protected function getCreatedEventAttributes(): array |
|
137 | { |
|
138 | $new = []; |
|
139 | ||
140 | foreach ($this->attributes as $attribute => $value) { |
|
141 | if ($this->isAttributeAuditable($attribute)) { |
|
142 | $new[$attribute] = $value; |
|
143 | } |
|
144 | } |
|
145 | ||
146 | return [ |
|
147 | [], |
|
148 | $new, |
|
149 | ]; |
|
150 | } |
|
151 | ||
152 | /** |
|
153 | * Get the old/new attributes of an updated event. |
|
@@ 180-194 (lines=15) @@ | ||
177 | * |
|
178 | * @return array |
|
179 | */ |
|
180 | protected function getDeletedEventAttributes(): array |
|
181 | { |
|
182 | $old = []; |
|
183 | ||
184 | foreach ($this->attributes as $attribute => $value) { |
|
185 | if ($this->isAttributeAuditable($attribute)) { |
|
186 | $old[$attribute] = $value; |
|
187 | } |
|
188 | } |
|
189 | ||
190 | return [ |
|
191 | $old, |
|
192 | [], |
|
193 | ]; |
|
194 | } |
|
195 | ||
196 | /** |
|
197 | * Get the old/new attributes of a restored event. |