Commit Graph

44 Commits

Author SHA1 Message Date
Mikael Nordfeldth
922b65d231 More debugging in Salmon since we get situations which can't find inReplyToID 2016-04-01 23:10:34 +02:00
Mikael Nordfeldth
e6f07d8554 Use in_array instead. Now we get third party responses to contextually interesting threads
I think this solves much of the "third party conversation" issues, assuming involved parties
are using modern GNU social instances.
2016-02-24 00:19:27 +01:00
Mikael Nordfeldth
31c9b2c1d8 Check the notice context for users in UsersalmonAction 2016-02-23 23:56:43 +01:00
Mikael Nordfeldth
0eb5122817 Check that the user is in the context of a salmon slap 2016-02-23 23:42:41 +01:00
Mikael Nordfeldth
b76461fc78 syntax error 2015-12-27 01:42:03 +01:00
Mikael Nordfeldth
0ac71c2b7b Duplicate URI means we have it already, I assume 2015-12-27 01:40:00 +01:00
Mikael Nordfeldth
c44146d6f8 Favorites are now being stored from activities 2014-07-02 18:38:19 +02:00
Mikael Nordfeldth
d0da552722 SalmonAction and extensions simplified 2014-06-28 20:33:09 +02:00
Mikael Nordfeldth
d534ea7bd6 Try the whole Salmon action for AlreadyFulfilledException
If we have already fulfilled the action, we don't have to send an error back.
2014-06-02 13:57:30 +02:00
Mikael Nordfeldth
63c20e59aa UsersalmonAction cleanup 2014-05-19 18:07:14 +02:00
Mikael Nordfeldth
7977361193 Too many bird wings ({), sorry Erkan :) 2014-05-07 09:52:50 +02:00
Mikael Nordfeldth
b59beb50e6 misplaced dollar sign, also URLs != attention URIs 2014-05-07 09:20:57 +02:00
Mikael Nordfeldth
8b12e41351 User object didn't have getNickname() function
We're just jumping on to the Profile->getNickname() function.
2014-05-06 16:08:36 +02:00
Mikael Nordfeldth
fc3125cf28 More modern coding, stuff related to subscriptions
Also trying to use the newly implemented AlreadyFulfilledException
2014-05-05 23:58:05 +02:00
Mikael Nordfeldth
805958cc23 UsersalmonAction updated to stronger typing standards 2014-05-05 19:38:01 +02:00
Joshua Judson Rosen
7440dc2145 Prevent spurious refusals of legitimate notices posted to users via Salmon.
Make the logic match the intent described in the comments.

The intent is clearly "accept notices whenever (A or B or C)", but
the logic implemented was more like "not ((not A) or (not B) or (not C))",
which is a basical boolean algebra fail (each of those ORs need to
become ANDs for double-negation to work).

The practical implication was that, for example, writing a reply
to someone else's notice and including an @-reference to _another_
user on another site to bring them into the discussion would
fail to deliver the notice to the new user because their server
would basically say `oh no, you can't message this user
from someone else's thread' because an earlier check for
the `A' or `C' parts of `(A or B or C)' prevents `B' from
being checked.

cf.: <http://status.hackerposse.com/notice/55846>, which was
refused by the nhcrossing.com server because it didn't know
about <http://sn.jonkman.ca/notice/93724>, even though it would
have passed the later `notice contains a reference to a local user'
check if not for an exception being prematurely thrown.

The whole idea of reporting `which specific check FAILED'
in an `if ANY SUCCEEDS' analysis is just bogus, so nix all of
the distinct ClientExceptions--a single `ALL FAILED' exception
is the only one that makes sense.
2014-05-05 13:35:38 +02:00
Mikael Nordfeldth
5fd6053220 Code cleanup and enabling User object's etc. getUri() 2014-04-28 14:08:42 +02:00
Mikael Nordfeldth
23a6b4595f Reworked the ActivityContext->attention structure
Removing Evan's obscure attentionType solution and directly using the attention array
2013-10-28 22:21:14 +01:00
Mikael Nordfeldth
2a4dc77a63 The overloaded DB_DataObject function staticGet is now called getKV
I used this hacky sed-command (run it from your GNU Social root, or change the first grep's path to where it actually lies) to do a rough fix on all ::staticGet calls and rename them to ::getKV

   sed -i -s -e '/DataObject::staticGet/I!s/::staticGet/::getKV/Ig' $(grep -R ::staticGet `pwd`/* | grep -v -e '^extlib' | grep -v DataObject:: |grep -v "function staticGet"|cut -d: -f1 |sort |uniq)

If you're applying this, remember to change the Managed_DataObject and Memcached_DataObject function definitions of staticGet to getKV!

This might of course take some getting used to, or modification fo StatusNet plugins, but the result is that all the static calls (to staticGet) are now properly made without breaking PHP Strict Standards. Standards are there to be followed (and they caused some very bad confusion when used with get_called_class)

Reasonably any plugin or code that tests for the definition of 'GNUSOCIAL' or similar will take this change into consideration.
2013-08-18 13:13:56 +02:00
Siebrand Mazeland
1fa689e913 tag -> list 2011-08-20 20:30:37 +02:00
Siebrand Mazeland
4651c9d94a Fix L10n/i18n.
Some remaining people tag -> list.
Favor -> like
Update translator documentation.
Whitespace updates.
2011-04-29 18:59:47 +02:00
Siebrand Mazeland
b83e0fd0e8 Update translator documentation.
i18n fixes (gettext domain).
L10n updates.
Whitespace updates.
Some tabs to spaces.
2011-04-11 00:39:51 +02: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
14456cbbb2 Fix gettext domain for messages in plugins "_()" to "_m()".
Some other i18n and L10n updates, too.

i18n/L10n review not complete.
2011-03-30 22:31:23 +02:00
Shashi Gowda
c335db4bbc OStatus support for people tags 2011-03-07 00:45:34 +05:30
Evan Prodromou
b54ea6767a New event for Salmon including target 2010-12-27 10:51:59 -08:00
Siebrand Mazeland
5a6f616206 * i18n/L10n update
* translator comments added
* remove superfluous whitespace
2010-09-19 15:17:36 +02:00
Evan Prodromou
ebcd8644a5 Revert "debugging replyToID"
This reverts commit bb9353f6e0.
2010-09-01 18:22:54 -04:00
Evan Prodromou
bb9353f6e0 debugging replyToID 2010-09-01 17:59:49 -04:00
Evan Prodromou
27626c3abf Correctly check for user's id in replies in user salmon post 2010-09-01 17:10:29 -04:00
Evan Prodromou
c82b1cda82 send a salmon slap to mentioned person when we reply to a notice 2010-09-01 14:35:43 -04:00
Evan Prodromou
029aa0c61c fix use of activity rather than act in salmonaction subclasses, too 2010-08-13 14:18:54 -07:00
Zach Copley
7b1b6045e6 Look for the first object in the Activity 2010-03-24 00:00:55 -07:00
Zach Copley
b8e97ac709 Some initial media parsing
- Activity now returns a list of activity objects
- Processing of photo objects
2010-03-22 18:55:17 -07:00
James Walker
9111c5c6fe allow profile_url to be used in ostatus:attention 2010-03-13 14:36:51 -05:00
Evan Prodromou
a9599d53c5 some info code for usersalmon.php 2010-02-21 23:39:52 -05:00
Evan Prodromou
e4c4f90c8a don't save Notices that already exist in Salmon 2010-02-21 23:32:20 -05:00
Evan Prodromou
232b5efa7e Add error info for missing URI in attention 2010-02-21 22:44:58 -05:00
Evan Prodromou
13fb7bef78 reversed in_array() arguments in UsersalmonAction 2010-02-21 22:41:02 -05:00
Evan Prodromou
4a4c34de32 Save posted notices in usersalmon 2010-02-21 09:17:35 -05:00
Evan Prodromou
6f1ccfc577 Subscription::start() should be enough, right? 2010-02-20 20:36:54 -05:00
Brion Vibber
145a19954f OStatus: Salmon favorite & unfavorite events now handled 2010-02-20 16:45:30 -08:00
Brion Vibber
f891b135fb OStatus: fix regressions in plugin & usersalmon action. Sub/unsub notifications are working again. 2010-02-20 10:26:32 -08:00
Evan Prodromou
2df3bbc80b Move some salmon processing to a superclass
Moved some salmon processing to a superclass so we could handle group
salmon posts, too.
2010-02-20 11:12:43 -05:00