mirror of
https://github.com/dmunozv04/iSponsorBlockTV.git
synced 2025-12-13 15:36:44 +03:00
Check tvOS instead of specific atv models
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import pyatv
|
||||
import json
|
||||
import asyncio
|
||||
from pyatv.const import DeviceModel
|
||||
from pyatv.const import OperatingSystem
|
||||
import sys
|
||||
import aiohttp
|
||||
import asyncio
|
||||
@@ -28,12 +28,7 @@ async def find_atvs(loop):
|
||||
atvs = []
|
||||
for i in devices:
|
||||
# Only get Apple TV's
|
||||
if i.device_info.model in [
|
||||
DeviceModel.Gen4,
|
||||
DeviceModel.Gen4K,
|
||||
DeviceModel.AppleTV4KGen2,
|
||||
]:
|
||||
# if i.device_info.model in [DeviceModel.AppleTV4KGen2]: #FOR TESTING
|
||||
if i.device_info.operating_system == OperatingSystem.TvOS:
|
||||
if input("Found {}. Do you want to add it? (y/n) ".format(i.name)) == "y":
|
||||
|
||||
identifier = i.identifier
|
||||
|
||||
Reference in New Issue
Block a user