Make sure to actually update other references as well
This commit is contained in:
parent
8fff0846a0
commit
10b2380e9e
1 changed files with 1 additions and 1 deletions
|
@ -34,7 +34,7 @@ class Fractal extends SpatieFractal
|
|||
// itself and set it automatically.
|
||||
$class = is_string($this->transformer) ? new $this->transformer() : $this->transformer;
|
||||
if (is_null($this->resourceName) && $class instanceof Transformer) {
|
||||
$this->resourceName = $this->transformer->getResourceName();
|
||||
$this->resourceName = $class->getResourceName();
|
||||
}
|
||||
|
||||
return parent::createData();
|
||||
|
|
Loading…
Reference in a new issue