summaryrefslogtreecommitdiff
path: root/classes/User.php
AgeCommit message (Collapse)Author
2010-07-29* mark a few message for translationSiebrand Mazeland
* add translator documentation
2010-07-19Make some messages gender neutral.Eric Helgeson
2010-05-05Implement since_id and max_id param handling for /api/favoritesZach Copley
2010-04-10Allow blocking someone who's not currently subscribed to you (prevents ↵Brion Vibber
seeing @-replies from them, or them subbing to you in future)
2010-03-31use Subscription::cancel() to cancel all subscriptions on blockEvan Prodromou
2010-03-28continue deleting even if user profile record is missingEvan Prodromou
2010-03-18Fix for xmpp/sms notification options appearing to be disabled on new ↵Brion Vibber
subscriptions. Base problem is that our caching-on-insert interferes with relying on column default values; the cached object is missing those fields, so they appear to be empty (null) when the object is retrieved from cache. Now explicitly setting them when inserting subscriptions, and cleaned up some code that had alternate code paths. May also have made auto-subscription work for remote OStatus subscribers, but can't test until magic sigs are working again.
2010-03-18Merge branch 'master' of git@gitorious.org:statusnet/mainline into testingBrion Vibber
2010-03-18Ensure that DB connection is active at start of User::updateKeys() and ↵Brion Vibber
Foreign_user::updateKeys(); calls to $this->_quote() require a live connection object and don't lazy-initialize themselves. May fix WSOD when changing incoming email address.
2010-03-18add exception on inconsistent db to User::getProfile()Evan Prodromou
2010-03-11Merge branch 'testing' of git@gitorious.org:statusnet/mainline into 0.9.xSarven Capadisli
2010-03-11Drop timestamp cutoff parameter from User::getCurrentNotice() and ↵Brion Vibber
Profile::getCurrentNotice(). It's not currently used, and won't be efficient when we update the notice.profile_id_idx index to optimize for our id-based sorting when pulling user post lists for profile pages, feeds etc.
2010-03-04Merge commit 'origin/testing' into 0.9.xBrion Vibber
Conflicts: lib/action.php lib/adminpanelaction.php
2010-03-03Use poster's subscribed groups to disambiguate group linking when a remote ↵Brion Vibber
group and a local group exist with the same name. (If you're a member of two groups with the same name though, there's not a defined winner.)
2010-03-02Merge branch 'testing' of git@gitorious.org:statusnet/mainline into 0.9.xBrion Vibber
2010-03-02Dropped deprecated timestamp-based 'since' parameter for all API methods. ↵Brion Vibber
When it sneaks in it can cause some very slow queries due to mismatches with the indexing. Twitter removed 'since' support some time ago, and we've already removed it from the public timeline, so it shouldn't be missed.
2010-02-26bail out if the requested nickname is illegalCraig Andrews
2010-02-19Refactor subs_* functions for remote useEvan Prodromou
The subs_* functions in subs.php have made a lot of assumptions about users versus profiles. I've refactored the functions to be methods of the Subscription class instead, and to use Profile objects throughout. Some of the checks for blocks or existing subscriptions depended on users or profiles, so I've moved those methods around a bit. I've left stubs for the subs_* functions until we get time to replace them.
2010-02-04Inbox::streamNotices() with deletion compensation: inbox paging should more ↵Brion Vibber
or less work with deleted items now. No change in efficiency for the common case where nothing's deleted: does the same bulk fetch of just the notices we think we'll need as before, then if we turned up short keeps checking one by one until we've filled up to our $limit. This can leave us with overlap between pages, but we already have that when new messages come in between clicks; seems to be the lesser of evils versus not getting a 'before' button. More permanent fix for that will be to switch timeline paging in the UI to use notice IDs.
2010-02-01restructuring of User::registerNew() lost password mungingEvan Prodromou
2010-01-31buggy fetch for site ownerEvan Prodromou
2010-01-29add hooks for user registrationEvan Prodromou
2010-01-29method to get the site ownerEvan Prodromou
2010-01-25Offload inbox updates to a queue handler to speed up posting onlineEvan Prodromou
Moved much of the writing that happens when posting a notice to a new queuehandler, distribqueuehandler. This updates tags, groups, replies and inboxes at queue time (or at Web time, if queues are disabled). To make this work well, I had to break up the monolithic Notice::blowCaches() and make cache blowing happen closer to where data is updated. Squashed commit of the following: commit 5257626c62750ac4ac1db0ce2b71410c5711cfa3 Author: Evan Prodromou <evan@status.net> Date: Mon Jan 25 14:56:41 2010 -0500 slightly better handling of blowing tag memory cache commit 8a22a3cdf6ec28685da129a0313e7b2a0837c9ef Author: Evan Prodromou <evan@status.net> Date: Mon Jan 25 01:42:56 2010 -0500 change 'distribute' to 'distrib' so not too long for dbqueue commit 7a063315b0f7fad27cb6fbd2bdd74e253af83e4f Author: Evan Prodromou <evan@status.net> Date: Mon Jan 25 01:39:15 2010 -0500 change handle_notice() to handle() in distributqueuehandler commit 1a39ccd28b9994137d7bfd21bb4f230546938e77 Author: Evan Prodromou <evan@status.net> Date: Mon Jan 25 16:05:25 2010 -0500 error with queuemanager commit e6b3bb93f305cfd2de71a6340b8aa6fb890049b7 Author: Evan Prodromou <evan@status.net> Date: Mon Jan 25 01:11:34 2010 -0500 Blow memcache at different point rather than one big function for Notice class commit 94d557cdc016187d1d0647ae1794cd94d6fb8ac8 Author: Evan Prodromou <evan@status.net> Date: Mon Jan 25 00:48:44 2010 -0500 Blow memcache at different point rather than one big function for Notice class commit 1c781dd08c88a35dafc5c01230b4872fd6b95182 Author: Evan Prodromou <evan@status.net> Date: Wed Jan 20 08:54:18 2010 -0500 move broadcasting and distributing to new queuehandler commit da3e46d26b84e4f028f34a13fd2ee373e4c1b954 Author: Evan Prodromou <evan@status.net> Date: Wed Jan 20 08:53:12 2010 -0500 Move distribution of notices to new distribute queue handler
2010-01-13unimplement repeatedToMe() until we figure out howEvan Prodromou
2010-01-09some formatting changes to make inblobs workEvan Prodromou
2010-01-09Use inbox instead of notice_inboxEvan Prodromou
2009-12-28More configuration options for location sharingEvan Prodromou
2009-12-28remove namespace setting from location; it's unusedEvan Prodromou
2009-12-28check if other user exists before unsubEvan Prodromou
2009-12-22Fix for massively slow friends timeline query due to indexing bug introduced ↵Brion Vibber
with repeats. Sorting on notice.id when our primary selector was notice_inbox.user_id caused a filesort and table scan of the notice table. Switchng to notice_inbox's notice_id means we can use our index, and everything comes right up. Before: mysql> explain SELECT notice.id AS id FROM notice JOIN notice_inbox ON notice.id = notice_inbox.notice_id WHERE notice_inbox.user_id = 18574 AND notice.repeat_of IS NULL ORDER BY notice.id DESC LIMIT 61 OFFSET 0; +----+-------------+--------------+--------+------------------------------------+---------+---------+-------------------------------+--------+----------------------------------------------+ | id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra | +----+-------------+--------------+--------+------------------------------------+---------+---------+-------------------------------+--------+----------------------------------------------+ | 1 | SIMPLE | notice_inbox | ref | PRIMARY,notice_inbox_notice_id_idx | PRIMARY | 4 | const | 102600 | Using index; Using temporary; Using filesort | | 1 | SIMPLE | notice | eq_ref | PRIMARY | PRIMARY | 4 | stoica.notice_inbox.notice_id | 1 | Using index | +----+-------------+--------------+--------+------------------------------------+---------+---------+-------------------------------+--------+----------------------------------------------+ After: mysql> explain SELECT notice.id AS id FROM notice JOIN notice_inbox ON notice.id = notice_inbox.notice_id WHERE notice_inbox.user_id = 18574 AND notice.repeat_of IS NULL ORDER BY notice_id DESC LIMIT 61 OFFSET 0; +----+-------------+--------------+--------+------------------------------------+---------+---------+-------------------------------+--------+--------------------------+ | id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra | +----+-------------+--------------+--------+------------------------------------+---------+---------+-------------------------------+--------+--------------------------+ | 1 | SIMPLE | notice_inbox | ref | PRIMARY,notice_inbox_notice_id_idx | PRIMARY | 4 | const | 102816 | Using where; Using index | | 1 | SIMPLE | notice | eq_ref | PRIMARY,notice_repeatof_idx | PRIMARY | 4 | stoica.notice_inbox.notice_id | 1 | Using where | +----+-------------+--------------+--------+------------------------------------+---------+---------+-------------------------------+--------+--------------------------+
2009-12-16Add doc comments listing the array parameters for User::register() and ↵Brion Vibber
Notice::saveNew()
2009-12-16Fix UserRightsTest unit testsBrion Vibber
2009-12-14add friends_timeline with no repeats in itEvan Prodromou
2009-12-12add statuses/retweeted_to_me to APIEvan Prodromou
2009-12-12add statuses/retweets_of_me to APIEvan Prodromou
2009-12-12add statuses/retweeted_by_me api actionEvan Prodromou
2009-12-03Was deleting wrong subscription during block. Now deletes the blockee's sub ↵Zach Copley
if it exists.
2009-12-03Make it impossible to block (and thus unsubscribe from yourZach Copley
self-subscription) via the API. Additionally, make it impossible to block yourself or unsubscribe from yourself, period. I also made User use the subs.php helper function for unsubscribing during a block. Hopefully, these changes will get rid of the problem of people accidentally deleting their self-subscriptions once and for all (knock on wood).
2009-11-17Merge branch '0.9.x' of git@gitorious.org:statusnet/mainline into 0.9.xEvan Prodromou
Conflicts: classes/statusnet.ini
2009-11-16Move rights check to profile and add right for new noticesEvan Prodromou
Added a right for new notices, realized that the hasRight() method should be on the profile, and moved it. Makes this a less atomic commit but that's the way it goes sometimes.
2009-11-16getGroups was not handling the case where limit=null correctlyCraig Andrews
2009-11-16change uses of User_role to Profile_roleEvan Prodromou
2009-11-16move role functions to Profile classEvan Prodromou
2009-11-15define rights around how to silence, sandbox, and delete a userEvan Prodromou
2009-11-12Added a User_username table that links the external username with a ↵Craig Andrews
StatusNet user_id Added EmailAuthenticationPlugin Added ReverseUsernameAuthenticationPlugin Changed the StartChangePassword and EndChangePassword events to take a user, instead of a nickname User::allowed_nickname was declared non-static, but used as if it was static, so I made the declaration static
2009-11-09Revert "Remove more contractions"Brion Vibber
This reverts commit 5ab709b73977131813884558bf56d97172a7aa26. Missed this one yesterday...
2009-11-08Remove more contractionsSiebrand Mazeland
* doesn't * won't * isn't * don't
2009-11-08Merge branch '0.9.x' of git@gitorious.org:statusnet/mainline into 0.9.xEvan Prodromou
2009-11-08Fix bug 1962: deleteuser.php regression when OpenID plugin not enabledBrion Vibber
The User_openid data object was explicitly listed as a related field to delete from in User::delete(); this class doesn't exist anymore by default since OpenID was broken out to a plugin. Added UserDeleteRelated event for plugins to add related tables to delete from at user delete time.