summaryrefslogtreecommitdiffstats
path: root/Auth/OpenID/SQLStore.php
diff options
context:
space:
mode:
authortailor <cygnus@janrain.com>2007-09-25 18:56:38 +0000
committertailor <cygnus@janrain.com>2007-09-25 18:56:38 +0000
commitb5e5cd7c3f57c915f16829c95a4cf681032885ee (patch)
treed604f2ef6dd10281d4c3019975a951f8d9bdfdb5 /Auth/OpenID/SQLStore.php
parentb914968d4fcb08550ef0ace91f99f7cd7e212ae0 (diff)
downloadphp-openid-b5e5cd7c3f57c915f16829c95a4cf681032885ee.zip
php-openid-b5e5cd7c3f57c915f16829c95a4cf681032885ee.tar.gz
php-openid-b5e5cd7c3f57c915f16829c95a4cf681032885ee.tar.bz2
[project @ Added store methods cleanupAssociations(), cleanup(), and concrete implementations]
Diffstat (limited to 'Auth/OpenID/SQLStore.php')
-rw-r--r--Auth/OpenID/SQLStore.php12
1 files changed, 11 insertions, 1 deletions
diff --git a/Auth/OpenID/SQLStore.php b/Auth/OpenID/SQLStore.php
index 4192022..15f7971 100644
--- a/Auth/OpenID/SQLStore.php
+++ b/Auth/OpenID/SQLStore.php
@@ -265,7 +265,8 @@ class Auth_OpenID_SQLStore extends Auth_OpenID_OpenIDStore {
'get_assoc',
'get_assocs',
'remove_assoc',
- 'get_expired')
+ 'get_expired',
+ 'clean_assoc')
)
);
@@ -570,6 +571,15 @@ class Auth_OpenID_SQLStore extends Auth_OpenID_OpenIDStore {
$this->connection->commit();
return $num;
}
+
+ function cleanupAssociations()
+ {
+ $this->connection->query($this->sql['clean_assoc'],
+ array(time()));
+ $num = $this->connection->affectedRows();
+ $this->connection->commit();
+ return $num;
+ }
}
?>