fix for update related tags

This commit is contained in:
albert
2013-02-20 10:23:50 -05:00
parent 46d1d3db59
commit 5d529bf4da
2 changed files with 4 additions and 2 deletions

View File

@@ -339,7 +339,9 @@ class Tag < ActiveRecord::Base
module RelationMethods module RelationMethods
def update_related def update_related
return unless should_update_related? return unless should_update_related?
self.related_tags = RelatedTagCalculator.calculate_from_sample_to_array(name).join(" ") CurrentUser.scoped(User.find(1)) do
self.related_tags = RelatedTagCalculator.calculate_from_sample_to_array(name).join(" ")
end
self.related_tags_updated_at = Time.now self.related_tags_updated_at = Time.now
save save
end end

View File

@@ -23,7 +23,7 @@
</tbody> </tbody>
</table> </table>
<%= sequential_paginator(@uploads) %> <%= numbered_paginator(@uploads) %>
</div> </div>
</div> </div>