Commit Graph

1590 Commits

Author SHA1 Message Date
Evan Prodromou
4742a2a87f Fix clone of null value 2011-04-10 18:40:28 -04:00
Siebrand Mazeland
f0d762f196 Update/add translator documentation.
L10n/i18n updates.
Superfluous whitespace removed.
Add FIXME for a few i18n issues I couldn't solve this quickly.

Takes care of documentation for all core code added in merge of "people tags" feature (Commit:e75c9988ebe33822e493ac225859bc593ff9b855).
2011-04-10 19:59:55 +02:00
Shashi Gowda
fc21e5c76b Fix type conversion warnings caused when calling getUser / getProfile for the second time 2011-04-09 22:16:52 +05:30
Shashi Gowda
f47027abbe Merge remote-tracking branch 'mainline/1.0.x' into people_tags_rebase
Conflicts:
	lib/profileblock.php
	theme/default/css/display.css
2011-04-09 21:57:45 +05:30
Shashi Gowda
4d61760154 Merge remote-tracking branch 'mainline/1.0.x' into people_tags_rebase 2011-04-08 17:16:20 +05:30
Evan Prodromou
731bdab804 Use pkeyGet() instead of idStream() for fave caching 2011-04-07 16:57:16 -04:00
Evan Prodromou
adf4d96013 store oft-requested stuff in the data object 2011-04-07 16:55:32 -04:00
Evan Prodromou
3e4016b388 do a short-term cache of notice scope 2011-04-07 16:24:56 -04:00
Evan Prodromou
84d848f78c correctly return values 2011-04-07 15:27:40 -04:00
Evan Prodromou
5dfb8e2bc4 Use InboxNoticeStream class for inbox
Move the code for inbox fetching to the InboxNoticeStream class.
2011-04-07 14:54:42 -04:00
Shashi Gowda
ad86eb78d3 Merge remote-tracking branch 'mainline/1.0.x' into people_tags_rebase
Conflicts:
	js/util.min.js
	lib/default.php
2011-04-07 23:13:45 +05:30
Evan Prodromou
5b9319d081 profiles were getting overwritten in Notice::asActivity() 2011-04-07 10:52:28 -04:00
Evan Prodromou
8a0f67b773 Uninitialized value for attachments 2011-04-07 10:25:53 -04:00
Evan Prodromou
f9dc2fc0ab cache getReplies() values 2011-04-06 23:46:51 -04:00
Evan Prodromou
419ae3f18d Cache results for attachments 2011-04-06 23:33:35 -04:00
Evan Prodromou
d3d0ec5ebe cache tags per notice 2011-04-06 23:25:24 -04:00
Evan Prodromou
59d0e2f373 cache the notice count for threaded view 2011-04-06 23:17:17 -04:00
Evan Prodromou
fa8592f50b Make Login_token use caching staticGet() 2011-04-06 22:51:46 -04:00
Evan Prodromou
b8fdf6636f make Group_block use caching staticGet() 2011-04-06 22:49:09 -04:00
Evan Prodromou
2a124c1397 make User_group use caching staticGet() 2011-04-06 22:48:33 -04:00
Evan Prodromou
44c64816a5 cache groups per notice 2011-04-06 22:47:17 -04:00
Evan Prodromou
29243cd21a make Profile::isMember() and Profile::isAdmin() use caching pkeyGet() 2011-04-06 18:12:25 -04:00
Evan Prodromou
b85c4923a2 Remove unused and non-standard USER_AGENT constant from File_redirection 2011-04-06 10:25:59 -04:00
Shashi Gowda
14aef781ad Use the cool and new NoticeStream for people tag timeline 2011-04-06 11:25:50 +05:30
Evan Prodromou
b3e7dd70e2 don't put bogus groups into the groups array 2011-04-05 18:27:01 -04:00
Evan Prodromou
efd2c68de9 cache groups per user 2011-04-05 17:20:17 -04:00
Shashi Gowda
ced00cf0bd Merge remote-tracking branch 'mainline/1.0.x' into people_tags_rebase 2011-04-05 10:28:05 +05:30
Evan Prodromou
797cd9ccd4 fix scope for replies to group-private notices 2011-04-04 22:34:47 -04:00
Evan Prodromou
eaa70d337d force the reply to a notice to have the same scope 2011-04-04 18:13:28 -04:00
Evan Prodromou
660f1cd6b8 Force group scope on notices sent to a private-only group
For groups that require a private scope, we force every notice to be limited to group scope.

Changed the group-discovery code so we only get groups once -- regardless if they were provided or not.
2011-04-04 17:33:42 -04:00
Evan Prodromou
b41c62a27c single flag for private groups 2011-04-04 16:58:52 -04:00
Evan Prodromou
82a357947d add force_scope flag to User_group 2011-04-04 16:24:43 -04:00
Shashi Gowda
57198a7464 Merge remote-tracking branch 'mainline/1.0.x' into people_tags_rebase
Conflicts:
	actions/tagother.php
	lib/subscriberspeopleselftagcloudsection.php
	lib/subscriptionspeopleselftagcloudsection.php
2011-04-04 13:26:27 +05:30
Siebrand Mazeland
f64c312942 Update translator documentation. 2011-03-31 22:48:03 +02:00
Evan Prodromou
f580147058 Clear ;last version of stream if importing old stuff 2011-03-31 16:15:05 -04:00
Evan Prodromou
8333ac33c8 if user has private stream flag, set that scope 2011-03-31 12:56:53 -04:00
Evan Prodromou
4f5355a9f2 add the private_stream attribute to User 2011-03-30 08:16:30 -04:00
Shashi Gowda
5a2bab07b2 Merge remote-tracking branch 'mainline/1.0.x' into people_tags_rebase
Conflicts:
	actions/tagother.php
	classes/Profile.php
	classes/Profile_tag.php
	js/util.min.js
2011-03-30 15:47:42 +05:30
Brion Vibber
2e56e11482 Note explicitly that you can pass null to Notice::inScope() 2011-03-29 17:01:53 -07:00
Brion Vibber
674e3c2a0e Merge branch '1.0.x' of gitorious.org:statusnet/mainline into 1.0.x
Conflicts:
	actions/apistatusesretweet.php
	actions/repeat.php
	classes/Notice.php
	lib/command.php
2011-03-29 16:26:20 -07:00
Brion Vibber
9adbb49fc9 Consolidate some precondition checks for repeats, fix a couple bits in the repeat command.
Notice::saveNew() now does these checks directly when making a repeat:
* make sure the original is valid and existing
* stop you from repeating your own message
* stop you from repeating something you've previously repeated
* prevent repeats of any non-public messages
* explicit inScope() check to make sure you can read the original too (just in case there's a funky extension at play that changes scoping rules)

These error conditions throw exceptions, which the caller either uses as an error message or passes on up the stack, without having to duplicate the checks in each i/o channel.
2011-03-29 16:20:12 -07:00
Brion Vibber
8286edce28 fix regression in group join approval due to refactoring (forgot to remove a param) 2011-03-29 16:18:51 -07:00
Siebrand Mazeland
0a19674c9f @evan Fixed message domain for messages in plugins for recent commits.
Numbered parameters when more than one used in a message.
L10n updates for consistency.
i18n for non-translatable exception.
Updated translator documentation.
Removed superfluous whitespace.
2011-03-30 00:48:41 +02:00
Evan Prodromou
9f1603462d Merge branch 'limitdist2' into 1.0.x 2011-03-29 17:32:17 -04:00
Siebrand Mazeland
700018fd09 L10n/i18n updated.
Translator documentation updated.
FIXME added for missing class documentation.
Various documentation tweaks.
2011-03-29 23:00:29 +02:00
Evan Prodromou
31fd4dbe3b Repeats keep the same scope as parent 2011-03-29 12:12:08 -04:00
Evan Prodromou
32145484c2 Disallow repeats (retweets) of private notices
We disallow repeating a notice (or whatever) if the scope of the
notice is too private. So, only notices that are public scope
(available to everyone in the world) or site scope (available to
everyone on the site) can be repeated.

Enforce this rule at a low level in Notice.php, and in the API,
commands, and Web UI. Repeat button doesn't appear on tightly-scoped
notices in the Web UI.
2011-03-29 11:53:26 -04:00
Evan Prodromou
e862dcdb8a Merge branch '1.0.x' into limitdist2 2011-03-28 21:56:34 -04:00
Brion Vibber
c1683d9925 Durr... got items in wrong order :D Fixed email notification for pending subscribes 2011-03-28 17:22:37 -07:00
Brion Vibber
5d31dd259a Subscription pending notification mail 2011-03-28 17:15:48 -07:00
Brion Vibber
e5b5c256a3 Working subscription approval! 2011-03-28 17:08:04 -07:00
Brion Vibber
a70e68e09c Work in progress: can create & cancel sub requests 2011-03-28 16:12:51 -07:00
Brion Vibber
df5def8ce4 Work in progress: subscription approval policy field in place on user, hooked up to settings. Queue not 100% tidied up, no UI for queue or management yet. 2011-03-28 15:13:59 -07:00
Brion Vibber
11b40ddb1b work in progress... 2011-03-28 13:59:48 -07:00
Brion Vibber
4eb02c624e Subscription_queue class for subscription approval 2011-03-28 13:59:48 -07:00
Evan Prodromou
b0deaad700 Add a check to prevent replying to an unscoped notice 2011-03-28 12:01:08 -04:00
Evan Prodromou
e11c69fd81 always allow author to see own notices 2011-03-26 16:47:18 -04:00
Evan Prodromou
82b38b62a4 clearer scope rules for anonymous and author 2011-03-26 16:23:20 -04:00
Evan Prodromou
c7f866b032 Caller can set scope for Notice::saveNew() 2011-03-26 15:49:46 -04:00
Evan Prodromou
0c3f8208cd Merge branch 'limitdist' into limitdist2 2011-03-25 11:46:49 -04:00
Evan Prodromou
44bcc942b8 Break up stream code to use separate notice stream classes
Rearchitect (again!) notice stream code to delegate different functionality up and down the stack.

Now, different classes implement NoticeStream.
2011-03-24 18:04:19 -04:00
Siebrand Mazeland
3be26565fb Update translator documentation.
i18n/L10n updates.
Superfluous whitespace removed.
Add FIXME in files with missing documentation.
2011-03-24 11:48:51 +01:00
Evan Prodromou
eb1faa7865 Merge branch '1.0.x' into limitdist
Conflicts:
	classes/Notice.php
2011-03-23 15:58:27 -04:00
Evan Prodromou
2b901894c2 Some fixes to make the notice stream class work 2011-03-23 11:59:01 -04:00
Evan Prodromou
efb6a7b441 let Inbox class go fingerpokin' in streams 2011-03-23 11:42:52 -04:00
Evan Prodromou
0b35ce7c37 New NoticeStream class to reify streams of notices
We've been muddling through with 6- or 8-argument functions for managing streams. I'd
like to start thinking of streams as their own thing, and give them some more value.

So, the new NoticeStream class takes over the Notice::stream() function and Notice::getStreamByIds().

There's probably some fine-tuning to do on the object interface.
2011-03-23 11:29:55 -04:00
Brion Vibber
14a6ab2b04 Refactoring on notification mail generation: common profile & footer chunks pulled out, notifications added for group joins. 2011-03-22 16:50:27 -07:00
Evan Prodromou
fd8dad3963 Merge branch 'limitdist' of gitorious.org:~evan/statusnet/evans-mainline into limitdist
Conflicts:
	classes/Notice.php
2011-03-22 18:17:09 -04:00
Evan Prodromou
31e7d46a5b add profile to stream function 2011-03-22 18:15:53 -04:00
Evan Prodromou
26a4bd7dbf move scope check to Notice so we can have a null profile 2011-03-22 11:56:28 -04:00
Evan Prodromou
7fc5679e7e function for checking scope rules for Profile 2011-03-22 11:56:28 -04:00
Evan Prodromou
6cdbe47e72 add scope flags for Notice 2011-03-22 11:56:28 -04:00
Evan Prodromou
7f74aa6c20 Add scope bitmap for notices 2011-03-22 11:56:28 -04:00
Evan Prodromou
83fb5e6023 Mass replacement of #-comments with //-comments
like leprous boils in our code. So, I've replaced all of them with //
comments instead. It's a massive, meaningless, and potentially buggy
change -- great one for the middle of a release cycle, eh?
2011-03-22 11:54:23 -04:00
Shashi Gowda
13e9e41d2f Blend in with some new code. New menus, etc. 2011-03-22 08:30:16 +05:30
Shashi Gowda
bf121a695a Merge remote-tracking branch 'mainline/1.0.x' into people_tags_rebase
Conflicts:
	classes/Profile.php
2011-03-22 07:59:06 +05:30
Shashi Gowda
31c1177970 Merge branch '1.0.x' into people_tags_rebase
Conflicts:
	EVENTS.txt
	actions/peopletag.php
	actions/tagother.php
	classes/Notice.php
	js/util.js
	js/util.min.js
	lib/accountprofileblock.php
	lib/action.php
	lib/activityobject.php
	lib/command.php
	lib/personalgroupnav.php
	plugins/OStatus/OStatusPlugin.php
2011-03-22 07:56:25 +05:30
Brion Vibber
942887ca8c Split up some list/form classes, and get the 'approve' and 'cancel' links on group member queue working. 2011-03-21 17:17:18 -07:00
Brion Vibber
6bdb1053ad Pending members queue list -- doesn't yet allow approval. 2011-03-21 16:40:10 -07:00
Brion Vibber
471a480587 Logic to have group joins turn into pending joins automatically when group is set to mod; allow users to cancel their pending group requests. 2011-03-21 16:26:41 -07:00
Brion Vibber
a54eb0941e Tweaking request_queue -> group_join_queue, easier to deal with the indexes and keys and caching this way. 2011-03-21 15:05:36 -07:00
Brion Vibber
541dfa04fe Switch things from calling Group_member::join & leave & calling events manually to running through Profile::joinGroup() && Profile::leaveGroup(), with the events encapsulated. 2011-03-21 14:35:29 -07:00
Brion Vibber
0bec9cfdbc Add request_queue table and user_group.join_policy column, for upcoming join & subscription moderation.
UI for setting the join policy is in, but not yet used.
2011-03-21 13:51:13 -07:00
Brion Vibber
90a7631592 Caching for conversation root lookup, some logic fixes in threaded view 2011-03-17 17:36:53 -07:00
Brion Vibber
0c2c73659c Use cached sources for favorites & repeats info on threaded notice lists 2011-03-17 17:06:04 -07:00
Evan Prodromou
9af92f94bd function for checking scope rules for Profile 2011-03-17 12:16:09 -04:00
Evan Prodromou
b8735f4911 add scope flags for Notice 2011-03-17 12:16:09 -04:00
Evan Prodromou
ef638b0f22 Add scope bitmap for notices 2011-03-17 12:16:09 -04:00
Brion Vibber
8de24335d2 Doc comment on Notice->getTags() to clarify the return data type 2011-03-15 12:51:29 -07:00
Brion Vibber
b66250c6aa Add StartNoticeWhoGets, EndNoticeWhoGets events to allow upcoming TagSub plugin to do extra inbox delivery. 2011-03-15 12:49:17 -07:00
Evan Prodromou
e1d177de7e store reply_to notices as comment activity objects 2011-03-07 14:27:23 -05:00
Evan Prodromou
32f4daf44d Notice saves its object type 2011-03-07 14:20:55 -05:00
Shashi Gowda
1b1a427237 DB_DataObjects for people tags 2011-03-06 23:28:03 +05:30
Brion Vibber
5519da95fd Merge branch 'master' into 0.9.x 2011-03-01 17:11:29 -08:00
Brion Vibber
4c09c1dc47 Workaround for bug causing fatal error during favoriting; Profile::getCurrentNotice() was returning an ArrayList instead of a Notice directly due to pulling through Profile::getNotices(). This caused failure in Fave::addNew() which specifies it wants a Notice. Caused failure of the 'fav' IM command. 2011-03-01 17:04:05 -08:00
Brion Vibber
d09aa9c947 Workaround for bug causing fatal error during favoriting; Profile::getCurrentNotice() was returning an ArrayList instead of a Notice directly due to pulling through Profile::getNotices(). This caused failure in Fave::addNew() which specifies it wants a Notice. Caused failure of the 'fav' IM command. 2011-03-01 17:01:35 -08:00
Brion Vibber
a7005f3975 Alternate Inbox streaming function optimized for threaded paging (for /all stream, while things using the existing API inbox methods won't be affected) 2011-03-01 15:16:39 -08:00
Zach Copley
b7d0746694 Merge branch '0.9.x' into 1.0.x
Conflicts:
	actions/confirmaddress.php
	actions/emailsettings.php
	actions/hostmeta.php
	actions/imsettings.php
	actions/login.php
	actions/profilesettings.php
	actions/showgroup.php
	actions/smssettings.php
	actions/urlsettings.php
	actions/userauthorization.php
	actions/userdesignsettings.php
	classes/Memcached_DataObject.php
	index.php
	lib/accountsettingsaction.php
	lib/action.php
	lib/common.php
	lib/connectsettingsaction.php
	lib/designsettings.php
	lib/personalgroupnav.php
	lib/profileaction.php
	lib/userprofile.php
	plugins/ClientSideShorten/ClientSideShortenPlugin.php
	plugins/Facebook/FBConnectSettings.php
	plugins/Facebook/FacebookPlugin.php
	plugins/NewMenu/NewMenuPlugin.php
	plugins/NewMenu/newmenu.css
2011-02-28 15:39:43 -08:00
Brion Vibber
2bd9532ebe Merge branch 'master' into 0.9.x 2011-02-28 10:18:18 -08:00
Brion Vibber
9ec395b07a Workaround for reply timeline since_id issue: save the notice.created value into reply.modified, so we can key off it as expected.
As a hack this removes the mysql_timestamp bit from the field settings on reply.modified so that our value actually gets saved. This *should* work ok as long as system timezone is set correctly, which we now set to UTC to match when connecting.
2011-02-25 13:22:13 -08:00