Merge pull request #369 from greg0ire/master
Show the advice only when relevant.
This commit is contained in:
commit
0c4952447b
@ -61,9 +61,11 @@ class ORMInvalidArgumentException extends \InvalidArgumentException
|
|||||||
. " configured to cascade persist operations for entity: " . self::objToStr($entry) . "."
|
. " configured to cascade persist operations for entity: " . self::objToStr($entry) . "."
|
||||||
. " To solve this issue: Either explicitly call EntityManager#persist()"
|
. " To solve this issue: Either explicitly call EntityManager#persist()"
|
||||||
. " on this unknown entity or configure cascade persist "
|
. " on this unknown entity or configure cascade persist "
|
||||||
. " this association in the mapping for example @ManyToOne(..,cascade={\"persist\"}). "
|
. " this association in the mapping for example @ManyToOne(..,cascade={\"persist\"})."
|
||||||
. " If you cannot find out which entity causes the problem"
|
. (method_exists($entry, '__toString') ?
|
||||||
. " implement '" . $assoc['targetEntity'] . "#__toString()' to get a clue.");
|
"":
|
||||||
|
" If you cannot find out which entity causes the problem"
|
||||||
|
." implement '" . $assoc['targetEntity'] . "#__toString()' to get a clue."));
|
||||||
}
|
}
|
||||||
|
|
||||||
static public function detachedEntityFoundThroughRelationship(array $assoc, $entry)
|
static public function detachedEntityFoundThroughRelationship(array $assoc, $entry)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user