Skip to content

Commit

Permalink
More scrutinizer docs updates
Browse files Browse the repository at this point in the history
  • Loading branch information
jtsternberg committed Jan 9, 2015
1 parent 8e478a9 commit 3301bec
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
6 changes: 3 additions & 3 deletions includes/CMB2_Field.php
Original file line number Diff line number Diff line change
Expand Up @@ -492,9 +492,9 @@ public function repeatable_exception( $type ) {
/**
* Escape the value before output. Defaults to 'esc_attr()'
* @since 1.0.1
* @param mixed $meta_value Meta value
* @param mixed $func Escaping function (if not esc_attr())
* @return mixed Final value
* @param mixed $meta_value Meta value
* @param callable $func Escaping function (if not esc_attr())
* @return mixed Final value
*/
public function escaped_value( $func = 'esc_attr', $meta_value = '' ) {

Expand Down
4 changes: 2 additions & 2 deletions includes/CMB2_Options.php
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ function get( $field_id, $default = false ) {
* @param mixed $value Value to update data with
* @param bool $resave Whether to re-save the data
* @param bool $single Whether data should not be an array
* @return array Modified options
* @return boolean Return status of update
*/
function update( $field_id, $value = '', $resave = false, $single = true ) {
$this->get_options();
Expand Down Expand Up @@ -128,7 +128,7 @@ function update( $field_id, $value = '', $resave = false, $single = true ) {
* overwriting the option value to be stored.
*
* @since 1.0.1
* @return boolean Success/Failure
* @return boolean Success/Failure
*/
function set( $options = false ) {
$this->options = $options ? $options : $this->options;
Expand Down
6 changes: 3 additions & 3 deletions includes/CMB2_Sanitize.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ class CMB2_Sanitize {
/**
* Setup our class vars
* @since 1.1.0
* @param object $field A CMB field object
* @param mixed $value Field value
* @param CMB2_Field $field A CMB field object
* @param mixed $value Field value
*/
public function __construct( CMB2_Field $field, $value ) {
$this->field = $field;
Expand Down Expand Up @@ -101,7 +101,7 @@ public function default_sanitization( $value ) {
* Simple checkbox validation
* @since 1.0.1
* @param mixed $value 'on' or false
* @return mixed 'on' or false
* @return string|false 'on' or false
*/
public function checkbox( $value ) {
return $value === 'on' ? 'on' : false;
Expand Down
6 changes: 3 additions & 3 deletions includes/helper-functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ function cmb2_get_option( $option_key, $field_id = '' ) {
* @param string $option_key Option key
* @param string $field_id Option array field key
* @param mixed $value Value to update data with
* @param bool $single Whether data should not be an array
* @return array Modified options
* @param boolean $single Whether data should not be an array
* @return boolean Success/Failure
*/
function cmb2_update_option( $option_key, $field_id, $value, $single = true ) {
if ( cmb2_options( $option_key )->update( $field_id, $value, false, $single ) ) {
Expand All @@ -101,7 +101,7 @@ function cmb2_update_option( $option_key, $field_id, $value, $single = true ) {
* @param array $field_id Field ID or all field arguments
* @param int $object_id Object ID
* @param string $object_type Type of object being saved. (e.g., post, user, comment, or options-page)
* @return object CMB2_Field object
* @return CMB2_Field|null CMB2_Field object unless metabox config cannot be found
*/
function cmb2_get_field( $meta_box, $field_id, $object_id = 0, $object_type = 'post' ) {

Expand Down

0 comments on commit 3301bec

Please sign in to comment.