[dw-free] Delete bin/worker/load-friends-gm, not used anymore.
[commit: http://hg.dwscoalition.org/dw-free/rev/dfdb5048760f]
http://bugs.dwscoalition.org/show_bug.cgi?id=3971
Remove unused worker script.
Patch by
pauamma.
Files modified:
http://bugs.dwscoalition.org/show_bug.cgi?id=3971
Remove unused worker script.
Patch by
![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Files modified:
- bin/worker/load-friends-gm
-------------------------------------------------------------------------------- diff -r 8753001e720b -r dfdb5048760f bin/worker/load-friends-gm --- a/bin/worker/load-friends-gm Mon Oct 03 02:37:27 2011 +0800 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,50 +0,0 @@ -#!/usr/bin/perl -# This code was forked from the LiveJournal project owned and operated -# by Live Journal, Inc. The code has been modified and expanded by -# Dreamwidth Studios, LLC. These files were originally licensed under -# the terms of the license supplied by Live Journal, Inc, which can -# currently be found at: -# -# http://code.livejournal.org/trac/livejournal/browser/trunk/LICENSE-LiveJournal.txt -# -# In accordance with the original license, this code and all its -# modifications are provided under the GNU General Public License. -# A copy of that license can be found in the LICENSE file included as -# part of this distribution. - -use strict; -use lib "$ENV{LJHOME}/cgi-bin"; -require 'ljlib.pl'; - -use LJ::Worker::Gearman; -use Storable; - -gearman_decl("load_friends" => \&load_friends); -gearman_decl("load_friend_friendof_uids" => \&load_friend_friendof_uids); -gearman_work(); - -sub load_friends { - my $job = shift; - my $args = Storable::thaw($job->arg); - my $uid = $args->{userid}; - my $mask = $args->{mask}; - - my $friends = LJ::_get_friends_db($uid, $mask); - - # nfreeze friends hashref and return - return Storable::nfreeze($friends); -} - -sub load_friend_friendof_uids { - my $job = shift; - my $args = Storable::thaw($job->arg); - - my $uid = $args->{uid}; - my $opts = $args->{opts}; - - my $u = LJ::load_userid($uid); - - my @uids = $u->_friend_friendof_uids_do(%$opts); - - return Storable::nfreeze(\@uids); -} --------------------------------------------------------------------------------