Skip to content

Commit

Permalink
Set encoding type for scraper script reader (#2574 #2568)
Browse files Browse the repository at this point in the history
  • Loading branch information
dgtlmoon authored Aug 19, 2024
1 parent 8a35d62 commit 730f37c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions changedetectionio/content_fetchers/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ class Fetcher():

def __init__(self):
import importlib.resources
self.xpath_element_js = importlib.resources.files("changedetectionio.content_fetchers.res").joinpath('xpath_element_scraper.js').read_text()
self.instock_data_js = importlib.resources.files("changedetectionio.content_fetchers.res").joinpath('stock-not-in-stock.js').read_text()
self.xpath_element_js = importlib.resources.files("changedetectionio.content_fetchers.res").joinpath('xpath_element_scraper.js').read_text(encoding='utf-8')
self.instock_data_js = importlib.resources.files("changedetectionio.content_fetchers.res").joinpath('stock-not-in-stock.js').read_text(encoding='utf-8')

@abstractmethod
def get_error(self):
Expand Down

0 comments on commit 730f37c

Please sign in to comment.