Skip to content

Commit

Permalink
Changed method name of reference to referenceable.
Browse files Browse the repository at this point in the history
  • Loading branch information
mreduar committed May 26, 2021
1 parent 56ba943 commit 1185e8a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

All notable changes to `laravel-balance` will be documented in this file

## 1.2.0 - 2021-05-26

- Changed name of reference to referenceable method to avoid null properties when eager loading

## 1.1.1 - 2021-05-26

- Fixed reference polymorphic relationship.
Expand Down
4 changes: 2 additions & 2 deletions src/Balance.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ public function balanceable()
*
* @return \Illuminate\Database\Eloquent\Relations\MorphTo
*/
public function reference()
public function referenceable()
{
return $this->morphTo('referenceable');
return $this->morphTo();
}
}

0 comments on commit 1185e8a

Please sign in to comment.