Skip to content

Commit

Permalink
Update scraper.py
Browse files Browse the repository at this point in the history
  • Loading branch information
royopa committed Jun 3, 2019
1 parent 617b7e4 commit bd21c15
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scraper.py
Expand Up @@ -13,6 +13,7 @@


def get_encoding_type(current_file):
detector = UniversalDetector()
detector.reset()
for line in file(current_file):
detector.feed(line)
Expand All @@ -24,7 +25,6 @@ def get_encoding_type(current_file):
def convertFileBestGuess(filename):
targetFormat = 'utf-8'
outputDir = os.path.join('downloads')
detector = UniversalDetector()
sourceFormats = ['ascii', 'iso-8859-1']
for format in sourceFormats:
try:
Expand Down

0 comments on commit bd21c15

Please sign in to comment.