acts_as_follower icon indicating copy to clipboard operation
acts_as_follower copied to clipboard

blocking followers doesn't seems to work

Open masterkain opened this issue 15 years ago • 5 comments

Test conducted with clean follows table: http://pastie.org/private/eqpsdmbjomzl5ts3rdq9g

Is this a known issue? thanks.

masterkain avatar Mar 29 '10 00:03 masterkain

Hi, this was not a know issue. The first two commands worked fine. The issue is with the 1st and 3rd command. Any idea whats up? Is the test suite passing?

If you could patch that'd be awesome, if not I'll try and fix this asap.

Thanks, ~ Tom

tcocca avatar Mar 29 '10 01:03 tcocca

You may want to check for follow value in follow and stop_following

>> v = nil
=> nil
>> p 'test' unless v
"test"

We can use either Rails' .blank? .present? or .nil? in logic, that seems to fix it for me on ruby 1.8.7 (2008-08-11 patchlevel 72) [universal-darwin10.0]

Something like:

Follow.create(:followable => followable, :follower => self) unless follow.present?

I still have to run the test coverage, I'm a bit in hurry right now but will do soon.

masterkain avatar Mar 29 '10 06:03 masterkain

is this still an open ticket?

seanahrens avatar Jun 05 '11 21:06 seanahrens

I'll check it out as soon as I have some time, unless you would be kind enough to put in some time testing? I think this was before the master supported rails3 ... maybe? Have you been experiencing problems with blocking?

tcocca avatar Jun 06 '11 10:06 tcocca

I haven't been experiencing any problems. When I wrote that message I was in the process of deciding whether to use the plugin, and just noticed there was an open ticket for about a year, so I wanted to know if it was still an issue. Although, I decided to use the plugin anyway without knowing for sure. Not using the block functionality yet, but if I try it and experience problems, I'll let you know. Cheers. Thanks for the plugin!

seanahrens avatar Jun 08 '11 07:06 seanahrens