Skip to content

Commit

Permalink
by Dave Reid: Fixed PHP4 incompatibility.
Browse files Browse the repository at this point in the history
  • Loading branch information
davereid committed Mar 17, 2009
1 parent 70361af commit b9b9e5b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion feedburner.admin.inc
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ function feedburner_build_overview($category) {
$rows = array();
foreach ($feeds as $feed) {
$row = array();
$row[] = l($feed['alias'], $feed['path'], array('attributes' => array('alt' => $feed['description'], 'title' => $feed['description'])));
$row[] = l($feed['alias'], $feed['alias'], array('alias' => TRUE, 'attributes' => array('alt' => $feed['description'], 'title' => $feed['description'])));
if (isset($feed['feedburner'])) {
$row[] = l($feed['feedburner'], _feedburner_construct_url($feed['feedburner']));
$row[] = l(t('Edit'), 'admin/build/feedburner/burn/'. $feed['path']);
Expand Down
11 changes: 5 additions & 6 deletions feedburner.module
Original file line number Diff line number Diff line change
Expand Up @@ -517,10 +517,10 @@ function feedburner_save($edit) {
* An object with the FeedBurner feed.
*/
function feedburner_load($where, $args = array()) {
foreach ($where as $key => &$value) {
foreach ($where as $key => $value) {
if (is_string($key)) {
$args[] = $value;
$value = $key .' = '. (is_numeric($value) ? '%d' : "'%s'");
$where[$key] = $key .' = '. (is_numeric($value) ? '%d' : "'%s'");
}
}

Expand All @@ -539,10 +539,10 @@ function feedburner_load($where, $args = array()) {
* An optional array of arguments.
*/
function feedburner_delete($where, $args = array()) {
foreach ($where as $key => &$value) {
foreach ($where as $key => $value) {
if (is_string($value)) {
$args[] = $value;
$value = $key .' = '. (is_numeric($value) ? '%d' : "'%s'");
$where[$key] = $key .' = '. (is_numeric($value) ? '%d' : "'%s'");
}
}

Expand Down Expand Up @@ -708,8 +708,7 @@ function feedburner_var($name, $default = NULL) {
$name = 'feedburner_'. $name;

if (!isset($defaults[$name])) {
drupal_set_message(t('Default variable for %variable not found.', array('%variable' => $name)), 'error');
watchdog('feedburner', 'Default variable for %variable not found.', array('%variable' => $name), WATCHDOG_WARNING);
trigger_error(t('Default variable for %variable not found.', array('%variable' => $name)));
}

return variable_get($name, isset($default) || !isset($defaults[$name]) ? $default : $defaults[$name]);
Expand Down

0 comments on commit b9b9e5b

Please sign in to comment.