Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minor cleanup to Highlighter types #3003

Merged
merged 5 commits into from
Jan 6, 2018
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fixes for PR
  • Loading branch information
jjatie committed Nov 15, 2017
commit df3b8526a2cc8aec09b73b41e51b33ab3f0791d0
6 changes: 4 additions & 2 deletions Source/Charts/Highlight/BarHighlighter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ open class BarHighlighter: ChartHighlighter
{
open override func getHighlight(x: CGFloat, y: CGFloat) -> Highlight?
{
guard let barData = (self.chart as? BarChartDataProvider)?.barData,
guard
let barData = (self.chart as? BarChartDataProvider)?.barData,
let high = super.getHighlight(x: x, y: y)
else { return nil }

Expand Down Expand Up @@ -67,7 +68,8 @@ open class BarHighlighter: ChartHighlighter
return high
}

guard let ranges = entry.ranges,
guard
let ranges = entry.ranges,
ranges.count > 0
else { return nil }

Expand Down