Skip to content

Commit

Permalink
Added https support for deep_links
Browse files Browse the repository at this point in the history
  • Loading branch information
mkanet committed Mar 7, 2024
1 parent 19cce1f commit 997692c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion custom_components/sonarr_upcoming_media/sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,8 @@ def extra_state_attributes(self):
pass
series_title = show['series']['title']
series_slug = series_title.lower().replace(' ', '-')
card_item['deep_link'] = f'http://{self.host}:{self.port}/series/{series_slug}'
protocol = 'https' if self.ssl else 'http'
card_item['deep_link'] = f'{protocol}://{self.host}:{self.port}/series/{series_slug}'
card_json.append(card_item)
attributes['data'] = card_json
return attributes
Expand Down

0 comments on commit 997692c

Please sign in to comment.