mirror of
https://github.com/simon987/opendirectories-bot.git
synced 2025-04-19 10:16:47 +00:00
Fixes problem with urls with no trailing slash
This commit is contained in:
parent
2d1261c0f1
commit
3596829b06
@ -1,6 +1,7 @@
|
|||||||
import requests
|
import requests
|
||||||
from parser import NginxParser, ApacheParser
|
from parser import NginxParser, ApacheParser
|
||||||
from crawl_report import ReportSaver, ReportBuilder
|
from crawl_report import ReportSaver, ReportBuilder
|
||||||
|
import os
|
||||||
|
|
||||||
|
|
||||||
class Crawler:
|
class Crawler:
|
||||||
@ -8,7 +9,7 @@ class Crawler:
|
|||||||
def __init__(self, url, test_url):
|
def __init__(self, url, test_url):
|
||||||
self.files = []
|
self.files = []
|
||||||
self.parsed_urls = []
|
self.parsed_urls = []
|
||||||
self.base_url = url
|
self.base_url = os.path.join(url, '')
|
||||||
|
|
||||||
if url.startswith("http"):
|
if url.startswith("http"):
|
||||||
if test_url:
|
if test_url:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user