mirror of
https://github.com/simon987/Simple-Incremental-Search-Tool.git
synced 2025-04-19 18:16:45 +00:00
Very minor refactor
This commit is contained in:
parent
4b151966b3
commit
213cc61da9
@ -1,6 +1,5 @@
|
|||||||
import json
|
import json
|
||||||
import elasticsearch
|
import elasticsearch
|
||||||
from elasticsearch.exceptions import TransportError
|
|
||||||
from threading import Thread
|
from threading import Thread
|
||||||
import subprocess
|
import subprocess
|
||||||
import requests
|
import requests
|
||||||
|
@ -29,7 +29,9 @@ class MimeGuesser:
|
|||||||
|
|
||||||
|
|
||||||
class ContentMimeGuesser(MimeGuesser):
|
class ContentMimeGuesser(MimeGuesser):
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
|
import magic
|
||||||
self.libmagic = magic.Magic(mime=True)
|
self.libmagic = magic.Magic(mime=True)
|
||||||
|
|
||||||
def guess_mime(self, full_path):
|
def guess_mime(self, full_path):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user