Skip to content

Commit

Permalink
Fixed getValueRecord method
Browse files Browse the repository at this point in the history
  • Loading branch information
colintucker committed Sep 11, 2017
1 parent e25722b commit 8d4a18c
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions src/Forms/FontIconField.php
Original file line number Diff line number Diff line change
Expand Up @@ -131,18 +131,6 @@ public function search(HTTPRequest $request)
return $this->respond($data);
}

/**
* Answers the record identified by the recorded field value.
*
* @return ArrayData
*/
public function getValueRecord()
{
if ($id = $this->Value()) {
return $this->getIconData($id);
}
}

/**
* Answers the result format defined for the receiver.
*
Expand Down Expand Up @@ -193,6 +181,18 @@ protected function getFormatClass()
return str_replace('{value}', '$ID', $this->backend->getFieldClasses());
}

/**
* Answers the record identified by the given value.
*
* @param mixed $id
*
* @return ViewableData
*/
protected function getValueRecord($id)
{
return $this->getIconData($id);
}

/**
* Answers an array data object for the given icon ID.
*
Expand Down

0 comments on commit 8d4a18c

Please sign in to comment.