diff --git a/docs/index.rst b/docs/index.rst index 0f3c387..9c73161 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -16,6 +16,16 @@ Welcome to pymorizon's documentation! utils + category + offer + utils + + + category + offer + utils + + Indices and tables ================== diff --git a/morizon/offer.py b/morizon/offer.py index 41b9055..93910c8 100644 --- a/morizon/offer.py +++ b/morizon/offer.py @@ -212,8 +212,9 @@ def get_voivodeship_for_offer(item, *args, **kwargs): def get_meta_data(markup): - data = str(markup).split('__layer.push({"property":')[1].split(',"company":')[0] - print(data) + data = str(markup).split('__layer.push({"property":')[1] + end = re.findall(r',"company"|,"event"', data)[0] + data = data.split(end)[0] data = json.loads(data) return data