Skip to content

Commit

Permalink
Remove unused method TextFilter.filter_text_by_name
Browse files Browse the repository at this point in the history
  • Loading branch information
mvz committed Jul 16, 2016
1 parent 68b93a5 commit f4fe606
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 11 deletions.
5 changes: 0 additions & 5 deletions publify_core/app/models/text_filter.rb
Expand Up @@ -25,11 +25,6 @@ def self.filter_text(text, filters)
text
end

def self.filter_text_by_name(text, filtername)
f = TextFilter.find_by_name(filtername)
f.filter_text text
end

def filter_text(text)
self.class.filter_text(text, [:macropre, markup, :macropost, filters].flatten)
end
Expand Down
6 changes: 0 additions & 6 deletions spec/models/text_filter_spec.rb
Expand Up @@ -113,10 +113,4 @@ def filter_text(text, filters)
end
end
end

it '#filter text by name' do
build_stubbed('markdown smartypants')
result = TextFilter.filter_text_by_name('*"foo"*', 'markdown smartypants')
expect(result).to eq('<p><em>&#8220;foo&#8221;</em></p>')
end
end

0 comments on commit f4fe606

Please sign in to comment.