You are here

function DB_common::_convertNullArrayValuesToEmpty in Flickr API 5

Converts all null values in an array to empty strings

@access protected

Parameters

array $array the array to be de-nullified (passed by reference):

Return value

void

2 calls to DB_common::_convertNullArrayValuesToEmpty()
DB_mysql::fetchInto in phpFlickr/PEAR/DB/mysql.php
Places a row from the result set into the given array
DB_pgsql::fetchInto in phpFlickr/PEAR/DB/pgsql.php
Places a row from the result set into the given array

File

phpFlickr/PEAR/DB/common.php, line 2137

Class

DB_common
DB_common is the base class from which each database driver class extends

Code

function _convertNullArrayValuesToEmpty(&$array) {
  foreach ($array as $key => $value) {
    if (is_null($value)) {
      $array[$key] = '';
    }
  }
}