Commit 87b2e6e2 authored by webchick's avatar webchick
Browse files

Issue #2372323 by alexpott, amateescu: Static loaders on entity types don't...

Issue #2372323 by alexpott, amateescu: Static loaders on entity types don't return a properly typed object
parent 17eca969
......@@ -431,6 +431,9 @@ public function getCacheTags() {
/**
* {@inheritdoc}
*
* @return static
* The entity object or NULL if there is no entity with the given ID.
*/
public static function load($id) {
$entity_manager = \Drupal::entityManager();
......@@ -439,6 +442,9 @@ public static function load($id) {
/**
* {@inheritdoc}
*
* @return static[]
* An array of entity objects indexed by their IDs.
*/
public static function loadMultiple(array $ids = NULL) {
$entity_manager = \Drupal::entityManager();
......@@ -447,6 +453,9 @@ public static function loadMultiple(array $ids = NULL) {
/**
* {@inheritdoc}
*
* @return static
* The entity object.
*/
public static function create(array $values = array()) {
$entity_manager = \Drupal::entityManager();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment