summaryrefslogtreecommitdiff
path: root/classes
diff options
context:
space:
mode:
authorEvan Prodromou <evan@prodromou.name>2008-12-23 14:21:29 -0500
committerEvan Prodromou <evan@prodromou.name>2008-12-23 14:21:29 -0500
commiteb2f9c98ac115ce67e9a740b200c832153ffa05c (patch)
tree562e524f12420a97fc66a5c9db0ccd6a1f9aea09 /classes
parentedbc0c665cc65875b4d14b79939233b1c9c06bb6 (diff)
replace NULL with null
Another global search-and-replace update. Here, I've replaced the PHP keyword 'NULL' with its lowercase version. This is another PEAR code standards change. darcs-hash:20081223192129-84dde-4a0182e0ec16a01ad88745ad3e08f7cb501aee0b.gz
Diffstat (limited to 'classes')
-rw-r--r--classes/Avatar.php6
-rw-r--r--classes/Channel.php10
-rw-r--r--classes/Command.php34
-rw-r--r--classes/CommandInterpreter.php52
-rw-r--r--classes/Confirm_address.php2
-rw-r--r--classes/Consumer.php2
-rw-r--r--classes/Fave.php2
-rw-r--r--classes/Foreign_link.php8
-rw-r--r--classes/Foreign_service.php2
-rw-r--r--classes/Foreign_subscription.php2
-rw-r--r--classes/Foreign_user.php4
-rw-r--r--classes/Invitation.php2
-rw-r--r--classes/Memcached_DataObject.php6
-rw-r--r--classes/Message.php2
-rw-r--r--classes/Nonce.php2
-rw-r--r--classes/Notice.php18
-rw-r--r--classes/NoticeWrapper.php2
-rw-r--r--classes/Notice_inbox.php2
-rw-r--r--classes/Notice_source.php2
-rw-r--r--classes/Notice_tag.php2
-rw-r--r--classes/Profile.php20
-rw-r--r--classes/Profile_block.php2
-rw-r--r--classes/Profile_tag.php2
-rw-r--r--classes/Queue_item.php10
-rw-r--r--classes/Remember_me.php2
-rw-r--r--classes/Remote_profile.php2
-rw-r--r--classes/Reply.php2
-rw-r--r--classes/Sms_carrier.php2
-rw-r--r--classes/Subscription.php2
-rw-r--r--classes/Token.php2
-rw-r--r--classes/User.php18
-rw-r--r--classes/User_openid.php2
32 files changed, 114 insertions, 114 deletions
diff --git a/classes/Avatar.php b/classes/Avatar.php
index e63668a33..bde983d79 100644
--- a/classes/Avatar.php
+++ b/classes/Avatar.php
@@ -21,7 +21,7 @@ class Avatar extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Avatar',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Avatar',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
@@ -72,7 +72,7 @@ class Avatar extends Memcached_DataObject
if ($scaled->insert()) {
return $scaled;
} else {
- return NULL;
+ return null;
}
}
@@ -85,7 +85,7 @@ class Avatar extends Memcached_DataObject
} else if ($this->mediatype == 'image/png') {
return imagecreatefrompng($filepath);
} else {
- return NULL;
+ return null;
}
}
diff --git a/classes/Channel.php b/classes/Channel.php
index 384fe8bb1..ea3530406 100644
--- a/classes/Channel.php
+++ b/classes/Channel.php
@@ -38,13 +38,13 @@ class Channel {
}
function source() {
- return NULL;
+ return null;
}
}
class XMPPChannel extends Channel {
- var $conn = NULL;
+ var $conn = null;
function source() {
return 'xmpp';
@@ -111,7 +111,7 @@ class WebChannel extends Channel {
# XXX: even better, redirect to appropriate page
# depending on what command was run
common_show_header(_('Command results'));
- common_element('p', NULL, $text);
+ common_element('p', null, $text);
common_show_footer();
}
@@ -149,13 +149,13 @@ class AjaxWebChannel extends WebChannel {
class MailChannel extends Channel {
- var $addr = NULL;
+ var $addr = null;
function source() {
return 'mail';
}
- function __construct($addr=NULL) {
+ function __construct($addr=null) {
$this->addr = $addr;
}
diff --git a/classes/Command.php b/classes/Command.php
index ff44b9d1e..b146005a7 100644
--- a/classes/Command.php
+++ b/classes/Command.php
@@ -23,9 +23,9 @@ require_once(INSTALLDIR.'/classes/Channel.php');
class Command {
- var $user = NULL;
+ var $user = null;
- function __construct($user=NULL) {
+ function __construct($user=null) {
$this->user = $user;
}
@@ -47,7 +47,7 @@ class TrackOffCommand extends UnimplementedCommand {
}
class TrackCommand extends UnimplementedCommand {
- var $word = NULL;
+ var $word = null;
function __construct($user, $word) {
parent::__construct($user);
$this->word = $word;
@@ -55,7 +55,7 @@ class TrackCommand extends UnimplementedCommand {
}
class UntrackCommand extends UnimplementedCommand {
- var $word = NULL;
+ var $word = null;
function __construct($user, $word) {
parent::__construct($user);
$this->word = $word;
@@ -63,7 +63,7 @@ class UntrackCommand extends UnimplementedCommand {
}
class NudgeCommand extends UnimplementedCommand {
- var $other = NULL;
+ var $other = null;
function __construct($user, $other) {
parent::__construct($user);
$this->other = $other;
@@ -71,7 +71,7 @@ class NudgeCommand extends UnimplementedCommand {
}
class InviteCommand extends UnimplementedCommand {
- var $other = NULL;
+ var $other = null;
function __construct($user, $other) {
parent::__construct($user);
$this->other = $other;
@@ -104,7 +104,7 @@ class StatsCommand extends Command {
class FavCommand extends Command {
- var $other = NULL;
+ var $other = null;
function __construct($user, $other) {
parent::__construct($user);
@@ -148,7 +148,7 @@ class FavCommand extends Command {
}
class WhoisCommand extends Command {
- var $other = NULL;
+ var $other = null;
function __construct($user, $other) {
parent::__construct($user);
$this->other = $other;
@@ -182,8 +182,8 @@ class WhoisCommand extends Command {
}
class MessageCommand extends Command {
- var $other = NULL;
- var $text = NULL;
+ var $other = null;
+ var $text = null;
function __construct($user, $other, $text) {
parent::__construct($user);
$this->other = $other;
@@ -225,7 +225,7 @@ class MessageCommand extends Command {
class GetCommand extends Command {
- var $other = NULL;
+ var $other = null;
function __construct($user, $other) {
parent::__construct($user);
@@ -255,7 +255,7 @@ class GetCommand extends Command {
class SubCommand extends Command {
- var $other = NULL;
+ var $other = null;
function __construct($user, $other) {
parent::__construct($user);
@@ -281,7 +281,7 @@ class SubCommand extends Command {
class UnsubCommand extends Command {
- var $other = NULL;
+ var $other = null;
function __construct($user, $other) {
parent::__construct($user);
@@ -305,8 +305,8 @@ class UnsubCommand extends Command {
}
class OffCommand extends Command {
- var $other = NULL;
- function __construct($user, $other=NULL) {
+ var $other = null;
+ function __construct($user, $other=null) {
parent::__construct($user);
$this->other = $other;
}
@@ -324,8 +324,8 @@ class OffCommand extends Command {
}
class OnCommand extends Command {
- var $other = NULL;
- function __construct($user, $other=NULL) {
+ var $other = null;
+ function __construct($user, $other=null) {
parent::__construct($user);
$this->other = $other;
}
diff --git a/classes/CommandInterpreter.php b/classes/CommandInterpreter.php
index 8192fb1a9..db02ce541 100644
--- a/classes/CommandInterpreter.php
+++ b/classes/CommandInterpreter.php
@@ -37,14 +37,14 @@ class CommandInterpreter {
switch(strtolower($cmd)) {
case 'help':
if ($arg) {
- return NULL;
+ return null;
}
return new HelpCommand($user);
case 'on':
if ($arg) {
list($other, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else {
return new OnCommand($user, $other);
}
@@ -55,7 +55,7 @@ class CommandInterpreter {
if ($arg) {
list($other, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else {
return new OffCommand($user, $other);
}
@@ -65,105 +65,105 @@ class CommandInterpreter {
case 'stop':
case 'quit':
if ($arg) {
- return NULL;
+ return null;
} else {
return new OffCommand($user);
}
case 'follow':
case 'sub':
if (!$arg) {
- return NULL;
+ return null;
}
list($other, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else {
return new SubCommand($user, $other);
}
case 'leave':
case 'unsub':
if (!$arg) {
- return NULL;
+ return null;
}
list($other, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else {
return new UnsubCommand($user, $other);
}
case 'get':
case 'last':
if (!$arg) {
- return NULL;
+ return null;
}
list($other, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else {
return new GetCommand($user, $other);
}
case 'd':
if (!$arg) {
- return NULL;
+ return null;
}
list($other, $extra) = explode(' ', $arg, 2);
if (!$extra) {
- return NULL;
+ return null;
} else {
return new MessageCommand($user, $other, $extra);
}
case 'whois':
if (!$arg) {
- return NULL;
+ return null;
}
list($other, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else {
return new WhoisCommand($user, $other);
}
case 'fav':
if (!$arg) {
- return NULL;
+ return null;
}
list($other, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else {
return new FavCommand($user, $other);
}
case 'nudge':
if (!$arg) {
- return NULL;
+ return null;
}
list($other, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else {
return new NudgeCommand($user, $other);
}
case 'stats':
if ($arg) {
- return NULL;
+ return null;
}
return new StatsCommand($user);
case 'invite':
if (!$arg) {
- return NULL;
+ return null;
}
list($other, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else {
return new InviteCommand($user, $other);
}
case 'track':
if (!$arg) {
- return NULL;
+ return null;
}
list($word, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else if ($word == 'off') {
return new TrackOffCommand($user);
} else {
@@ -171,11 +171,11 @@ class CommandInterpreter {
}
case 'untrack':
if (!$arg) {
- return NULL;
+ return null;
}
list($word, $extra) = explode(' ', $arg, 2);
if ($extra) {
- return NULL;
+ return null;
} else if ($word == 'all') {
return new TrackOffCommand($user);
} else {
@@ -184,7 +184,7 @@ class CommandInterpreter {
case 'tracks':
case 'tracking':
if ($arg) {
- return NULL;
+ return null;
}
return new TrackingCommand($user);
default:
diff --git a/classes/Confirm_address.php b/classes/Confirm_address.php
index 10661ff5c..71f2d0c72 100644
--- a/classes/Confirm_address.php
+++ b/classes/Confirm_address.php
@@ -20,7 +20,7 @@ class Confirm_address extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Confirm_address',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Confirm_address',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Consumer.php b/classes/Consumer.php
index d18e6feeb..c598312aa 100644
--- a/classes/Consumer.php
+++ b/classes/Consumer.php
@@ -16,7 +16,7 @@ class Consumer extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Consumer',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Consumer',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Fave.php b/classes/Fave.php
index b70a8a897..5d938d149 100644
--- a/classes/Fave.php
+++ b/classes/Fave.php
@@ -15,7 +15,7 @@ class Fave extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Fave',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Fave',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Foreign_link.php b/classes/Foreign_link.php
index 7ce0df833..41a95e641 100644
--- a/classes/Foreign_link.php
+++ b/classes/Foreign_link.php
@@ -21,7 +21,7 @@ class Foreign_link extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Foreign_link',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Foreign_link',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
@@ -38,7 +38,7 @@ class Foreign_link extends Memcached_DataObject
return $flink;
}
- return NULL;
+ return null;
}
static function getByForeignID($foreign_id, $service) {
@@ -51,7 +51,7 @@ class Foreign_link extends Memcached_DataObject
return $flink;
}
- return NULL;
+ return null;
}
# Convenience methods
@@ -66,7 +66,7 @@ class Foreign_link extends Memcached_DataObject
return $fuser;
}
- return NULL;
+ return null;
}
function getUser() {
diff --git a/classes/Foreign_service.php b/classes/Foreign_service.php
index 18ef83d69..128411b71 100644
--- a/classes/Foreign_service.php
+++ b/classes/Foreign_service.php
@@ -17,7 +17,7 @@ class Foreign_service extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Foreign_service',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Foreign_service',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Foreign_subscription.php b/classes/Foreign_subscription.php
index 315064067..d8e8569fb 100644
--- a/classes/Foreign_subscription.php
+++ b/classes/Foreign_subscription.php
@@ -16,7 +16,7 @@ class Foreign_subscription extends Memcached_DataObject
public $created; // datetime() not_null
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Foreign_subscription',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Foreign_subscription',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Foreign_user.php b/classes/Foreign_user.php
index 396680128..f8a980884 100644
--- a/classes/Foreign_user.php
+++ b/classes/Foreign_user.php
@@ -18,7 +18,7 @@ class Foreign_user extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Foreign_user',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Foreign_user',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
@@ -36,7 +36,7 @@ class Foreign_user extends Memcached_DataObject
return $fuser;
}
- return NULL;
+ return null;
}
function updateKeys(&$orig) {
diff --git a/classes/Invitation.php b/classes/Invitation.php
index 1477391b0..ff6456445 100644
--- a/classes/Invitation.php
+++ b/classes/Invitation.php
@@ -17,7 +17,7 @@ class Invitation extends Memcached_DataObject
public $created; // datetime() not_null
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Invitation',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Invitation',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Memcached_DataObject.php b/classes/Memcached_DataObject.php
index 7699e1b38..1d12730c9 100644
--- a/classes/Memcached_DataObject.php
+++ b/classes/Memcached_DataObject.php
@@ -23,7 +23,7 @@ require_once INSTALLDIR.'/classes/Memcached_DataObject.php';
class Memcached_DataObject extends DB_DataObject
{
- function &staticGet($cls, $k, $v=NULL) {
+ function &staticGet($cls, $k, $v=null) {
if (is_null($v)) {
$v = $k;
# XXX: HACK!
@@ -56,7 +56,7 @@ class Memcached_DataObject extends DB_DataObject
if ($i->find(true)) {
$i->encache();
} else {
- $i = NULL;
+ $i = null;
}
return $i;
}
@@ -67,7 +67,7 @@ class Memcached_DataObject extends DB_DataObject
return $result;
}
- function update($orig=NULL) {
+ function update($orig=null) {
if (is_object($orig) && $orig instanceof Memcached_DataObject) {
$orig->decache(); # might be different keys
}
diff --git a/classes/Message.php b/classes/Message.php
index dc527fcb1..e04fbb3c0 100644
--- a/classes/Message.php
+++ b/classes/Message.php
@@ -22,7 +22,7 @@ class Message extends Memcached_DataObject
public $source; // varchar(32)
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Message',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Message',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Nonce.php b/classes/Nonce.php
index 89d673c53..54d20de9c 100644
--- a/classes/Nonce.php
+++ b/classes/Nonce.php
@@ -18,7 +18,7 @@ class Nonce extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Nonce',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Nonce',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Notice.php b/classes/Notice.php
index 35e03e342..e6152812c 100644
--- a/classes/Notice.php
+++ b/classes/Notice.php
@@ -48,7 +48,7 @@ class Notice extends Memcached_DataObject
public $source; // varchar(32)
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Notice',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Notice',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
@@ -91,7 +91,7 @@ class Notice extends Memcached_DataObject
return true;
}
- static function saveNew($profile_id, $content, $source=NULL, $is_local=1, $reply_to=NULL, $uri=NULL) {
+ static function saveNew($profile_id, $content, $source=null, $is_local=1, $reply_to=null, $uri=null) {
$profile = Profile::staticGet($profile_id);
@@ -293,7 +293,7 @@ class Notice extends Memcached_DataObject
# XXX: too many args; we need to move to named params or even a separate
# class for notice streams
- static function getStream($qry, $cachekey, $offset=0, $limit=20, $since_id=0, $before_id=0, $order=NULL, $since=NULL) {
+ static function getStream($qry, $cachekey, $offset=0, $limit=20, $since_id=0, $before_id=0, $order=null, $since=null) {
if (common_config('memcached', 'enabled')) {
@@ -383,7 +383,7 @@ class Notice extends Memcached_DataObject
# If outside our cache window, just go to the DB
if ($offset + $limit > NOTICE_CACHE_WINDOW) {
- return Notice::getStreamDirect($qry, $offset, $limit, NULL, NULL, $order, NULL);
+ return Notice::getStreamDirect($qry, $offset, $limit, null, null, $order, null);
}
# Get the cache; if we can't, just go to the DB
@@ -391,7 +391,7 @@ class Notice extends Memcached_DataObject
$cache = common_memcache();
if (!$cache) {
- return Notice::getStreamDirect($qry, $offset, $limit, NULL, NULL, $order, NULL);
+ return Notice::getStreamDirect($qry, $offset, $limit, null, null, $order, null);
}
# Get the notices out of the cache
@@ -423,7 +423,7 @@ class Notice extends Memcached_DataObject
# bet with our DB.
$new_notice = Notice::getStreamDirect($qry, 0, NOTICE_CACHE_WINDOW,
- $last_id, NULL, $order, NULL);
+ $last_id, null, $order, null);
if ($new_notice) {
$new_notices = array();
@@ -447,7 +447,7 @@ class Notice extends Memcached_DataObject
# Otherwise, get the full cache window out of the DB
- $notice = Notice::getStreamDirect($qry, 0, NOTICE_CACHE_WINDOW, NULL, NULL, $order, NULL);
+ $notice = Notice::getStreamDirect($qry, 0, NOTICE_CACHE_WINDOW, null, null, $order, null);
# If there are no hits, just return the value
@@ -477,7 +477,7 @@ class Notice extends Memcached_DataObject
return $wrapper;
}
- function publicStream($offset=0, $limit=20, $since_id=0, $before_id=0, $since=NULL) {
+ function publicStream($offset=0, $limit=20, $since_id=0, $before_id=0, $since=null) {
$parts = array();
@@ -496,7 +496,7 @@ class Notice extends Memcached_DataObject
return Notice::getStream($qry,
'public',
- $offset, $limit, $since_id, $before_id, NULL, $since);
+ $offset, $limit, $since_id, $before_id, null, $since);
}
function addToInboxes() {
diff --git a/classes/NoticeWrapper.php b/classes/NoticeWrapper.php
index edecb3092..19ae37c1b 100644
--- a/classes/NoticeWrapper.php
+++ b/classes/NoticeWrapper.php
@@ -35,7 +35,7 @@ class NoticeWrapper extends Notice {
public $is_local; // tinyint(1)
public $source; // varchar(32)
- var $notices = NULL;
+ var $notices = null;
var $i = -1;
function __construct($arr) {
diff --git a/classes/Notice_inbox.php b/classes/Notice_inbox.php
index cc482bd19..922ba2660 100644
--- a/classes/Notice_inbox.php
+++ b/classes/Notice_inbox.php
@@ -33,7 +33,7 @@ class Notice_inbox extends Memcached_DataObject
public $source; // tinyint(1) default_1
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Notice_inbox',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Notice_inbox',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Notice_source.php b/classes/Notice_source.php
index e0a41b927..a12397b0b 100644
--- a/classes/Notice_source.php
+++ b/classes/Notice_source.php
@@ -17,7 +17,7 @@ class Notice_source extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Notice_source',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Notice_source',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Notice_tag.php b/classes/Notice_tag.php
index 84c4a1020..8c3911f76 100644
--- a/classes/Notice_tag.php
+++ b/classes/Notice_tag.php
@@ -30,7 +30,7 @@ class Notice_tag extends Memcached_DataObject
public $created; // datetime() not_null
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Notice_tag',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Notice_tag',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Profile.php b/classes/Profile.php
index 1f4508bf1..b95cbf993 100644
--- a/classes/Profile.php
+++ b/classes/Profile.php
@@ -41,12 +41,12 @@ class Profile extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Profile',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Profile',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
- function getAvatar($width, $height=NULL) {
+ function getAvatar($width, $height=null) {
if (is_null($height)) {
$height = $width;
}
@@ -62,7 +62,7 @@ class Profile extends Memcached_DataObject
if ($avatar->find(true)) {
return $avatar;
} else {
- return NULL;
+ return null;
}
}
@@ -71,12 +71,12 @@ class Profile extends Memcached_DataObject
$info = @getimagesize($source);
if (!$info) {
- return NULL;
+ return null;
}
$filename = common_avatar_filename($this->id,
image_type_to_extension($info[2]),
- NULL, common_timestamp());
+ null, common_timestamp());
$filepath = common_avatar_path($filename);
copy($source, $filepath);
@@ -96,12 +96,12 @@ class Profile extends Memcached_DataObject
if (!$this->delete_avatars()) {
@unlink($filepath);
- return NULL;
+ return null;
}
if (!$avatar->insert()) {
@unlink($filepath);
- return NULL;
+ return null;
}
foreach (array(AVATAR_PROFILE_SIZE, AVATAR_STREAM_SIZE, AVATAR_MINI_SIZE) as $size) {
@@ -109,7 +109,7 @@ class Profile extends Memcached_DataObject
if (!($avatar->width == $size && $avatar->height == $size)) {
$s = $avatar->scale($size);
if (!$s) {
- return NULL;
+ return null;
}
}
}
@@ -132,7 +132,7 @@ class Profile extends Memcached_DataObject
}
# Get latest notice on or before date; default now
- function getCurrentNotice($dt=NULL) {
+ function getCurrentNotice($dt=null) {
$notice = new Notice();
$notice->profile_id = $this->id;
if ($dt) {
@@ -143,7 +143,7 @@ class Profile extends Memcached_DataObject
if ($notice->find(true)) {
return $notice;
}
- return NULL;
+ return null;
}
function getNotices($offset=0, $limit=NOTICES_PER_PAGE, $since_id=0, $before_id=0) {
diff --git a/classes/Profile_block.php b/classes/Profile_block.php
index 6ea26a3bc..41d6701eb 100644
--- a/classes/Profile_block.php
+++ b/classes/Profile_block.php
@@ -36,7 +36,7 @@ class Profile_block extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Profile_block',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Profile_block',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Profile_tag.php b/classes/Profile_tag.php
index 2daabf867..5c508c84f 100644
--- a/classes/Profile_tag.php
+++ b/classes/Profile_tag.php
@@ -16,7 +16,7 @@ class Profile_tag extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Profile_tag',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Profile_tag',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Queue_item.php b/classes/Queue_item.php
index e54b4976b..f2fc0be03 100644
--- a/classes/Queue_item.php
+++ b/classes/Queue_item.php
@@ -16,7 +16,7 @@ class Queue_item extends Memcached_DataObject
public $claimed; // datetime()
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Queue_item',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Queue_item',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
@@ -28,7 +28,7 @@ class Queue_item extends Memcached_DataObject
$qi = new Queue_item();
$qi->transport = $transport;
$qi->orderBy('created');
- $qi->whereAdd('claimed is NULL');
+ $qi->whereAdd('claimed is null');
$qi->limit(1);
@@ -36,7 +36,7 @@ class Queue_item extends Memcached_DataObject
if ($cnt) {
# XXX: potential race condition
- # can we force it to only update if claimed is still NULL
+ # can we force it to only update if claimed is still null
# (or old)?
common_log(LOG_INFO, 'claiming queue item = ' . $qi->notice_id . ' for transport ' . $transport);
$orig = clone($qi);
@@ -49,7 +49,7 @@ class Queue_item extends Memcached_DataObject
common_log(LOG_INFO, 'claim failed.');
}
}
- $qi = NULL;
- return NULL;
+ $qi = null;
+ return null;
}
}
diff --git a/classes/Remember_me.php b/classes/Remember_me.php
index 5bbd6cf17..9d3f9378f 100644
--- a/classes/Remember_me.php
+++ b/classes/Remember_me.php
@@ -15,7 +15,7 @@ class Remember_me extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Remember_me',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Remember_me',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Remote_profile.php b/classes/Remote_profile.php
index c961dcca2..66b0f3a5c 100644
--- a/classes/Remote_profile.php
+++ b/classes/Remote_profile.php
@@ -38,7 +38,7 @@ class Remote_profile extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Remote_profile',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Remote_profile',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Reply.php b/classes/Reply.php
index d71ce3afb..10d6ced5b 100644
--- a/classes/Reply.php
+++ b/classes/Reply.php
@@ -16,7 +16,7 @@ class Reply extends Memcached_DataObject
public $replied_id; // int(4)
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Reply',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Reply',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Sms_carrier.php b/classes/Sms_carrier.php
index f6e0791f9..b4a9d8655 100644
--- a/classes/Sms_carrier.php
+++ b/classes/Sms_carrier.php
@@ -17,7 +17,7 @@ class Sms_carrier extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Sms_carrier',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Sms_carrier',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Subscription.php b/classes/Subscription.php
index a3b5e4b90..d70f99550 100644
--- a/classes/Subscription.php
+++ b/classes/Subscription.php
@@ -40,7 +40,7 @@ class Subscription extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Subscription',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Subscription',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/Token.php b/classes/Token.php
index d180ecebe..3c88444c8 100644
--- a/classes/Token.php
+++ b/classes/Token.php
@@ -19,7 +19,7 @@ class Token extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Token',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('Token',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
diff --git a/classes/User.php b/classes/User.php
index c2c6ad57f..29e6a86e9 100644
--- a/classes/User.php
+++ b/classes/User.php
@@ -62,7 +62,7 @@ class User extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('User',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('User',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE
@@ -118,10 +118,10 @@ class User extends Memcached_DataObject
return !in_array($nickname, $merged);
}
- function getCurrentNotice($dt=NULL) {
+ function getCurrentNotice($dt=null) {
$profile = $this->getProfile();
if (!$profile) {
- return NULL;
+ return null;
}
return $profile->getCurrentNotice($dt);
}
@@ -336,20 +336,20 @@ class User extends Memcached_DataObject
return $user;
}
- function getReplies($offset=0, $limit=NOTICES_PER_PAGE, $since_id=0, $before_id=0, $since=NULL) {
+ function getReplies($offset=0, $limit=NOTICES_PER_PAGE, $since_id=0, $before_id=0, $since=null) {
$qry =
'SELECT notice.* ' .
'FROM notice JOIN reply ON notice.id = reply.notice_id ' .
'WHERE reply.profile_id = %d ';
return Notice::getStream(sprintf($qry, $this->id),
'user:replies:'.$this->id,
- $offset, $limit, $since_id, $before_id, NULL, $since);
+ $offset, $limit, $since_id, $before_id, null, $since);
}
- function getNotices($offset=0, $limit=NOTICES_PER_PAGE, $since_id=0, $before_id=0, $since=NULL) {
+ function getNotices($offset=0, $limit=NOTICES_PER_PAGE, $since_id=0, $before_id=0, $since=null) {
$profile = $this->getProfile();
if (!$profile) {
- return NULL;
+ return null;
} else {
return $profile->getNotices($offset, $limit, $since_id, $before_id);
}
@@ -365,7 +365,7 @@ class User extends Memcached_DataObject
$offset, $limit);
}
- function noticesWithFriends($offset=0, $limit=NOTICES_PER_PAGE, $since_id=0, $before_id=0, $since=NULL) {
+ function noticesWithFriends($offset=0, $limit=NOTICES_PER_PAGE, $since_id=0, $before_id=0, $since=null) {
$enabled = common_config('inboxes', 'enabled');
# Complicated code, depending on whether we support inboxes yet
@@ -377,7 +377,7 @@ class User extends Memcached_DataObject
'SELECT notice.* ' .
'FROM notice JOIN subscription ON notice.profile_id = subscription.subscribed ' .
'WHERE subscription.subscriber = %d ';
- $order = NULL;
+ $order = null;
} else if ($enabled === true ||
($enabled == 'transitional' && $this->inboxed == 1)) {
diff --git a/classes/User_openid.php b/classes/User_openid.php
index ad68f7402..7dc476dc4 100644
--- a/classes/User_openid.php
+++ b/classes/User_openid.php
@@ -17,7 +17,7 @@ class User_openid extends Memcached_DataObject
public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
/* Static get */
- function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('User_openid',$k,$v); }
+ function staticGet($k,$v=null) { return Memcached_DataObject::staticGet('User_openid',$k,$v); }
/* the code above is auto generated do not remove the tag below */
###END_AUTOCODE