mirror of
https://github.com/Growstuff/growstuff.git
synced 2026-10-17 20:54:57 -04:00
lint
This commit is contained in:
1 parent
33460bb171
commit
f86177e78f
3 files changed
+5
-5
No files matched your search
@@ -11,7 +11,7 @@ module HarvestsHelper
|
||||
end
|
||||
|
||||
def display_human_quantity(harvest)
|
||||
return unless harvest.quantity.present? && harvest.quantity > 0
|
||||
return unless harvest.quantity.present? && harvest.quantity > 0
|
||||
|
||||
if harvest.unit == 'individual' # just the number
|
||||
number_to_human(harvest.quantity, strip_insignificant_zeros: true)
|
||||
|
||||
@@ -9,9 +9,9 @@ module SeedsHelper
|
||||
|
||||
def display_seed_description(seed)
|
||||
if seed.description.present?
|
||||
truncate(seed.description, length: 130, separator: ' ', omission: '... ') { link_to "Read more", seed_path(seed) }
|
||||
else
|
||||
''
|
||||
return truncate(seed.description, length: 130, separator: ' ', omission: '... ') { link_to "Read more", seed_path(seed) }
|
||||
end
|
||||
|
||||
''
|
||||
end
|
||||
end
|
||||
@@ -86,7 +86,7 @@ describe "plantings/show" do
|
||||
end
|
||||
|
||||
it "shows the member's location in parentheses" do
|
||||
expect(rendered).to have_content "#{planting.owner.location}"
|
||||
expect(rendered).to have_content planting.owner.location.to_s
|
||||
end
|
||||
end
|
||||
end
|
||||
Reference in new issue
Block a user