Selaa lähdekoodia

Move InputURL handling to base Module.__init__ and extract URL string for convenience

tags/v1.0
JustAnotherArchivist 4 vuotta sitten
vanhempi
commit
9f6e5a9f48
2 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. +1
    -0
      codearchiver/core.py
  2. +1
    -2
      codearchiver/modules/git.py

+ 1
- 0
codearchiver/core.py Näytä tiedosto

@@ -123,6 +123,7 @@ class Module:

def __init__(self, inputUrl):
self._inputUrl = inputUrl
self._url = inputUrl.url
self._httpClient = HttpClient()

@abc.abstractmethod


+ 1
- 2
codearchiver/modules/git.py Näytä tiedosto

@@ -15,8 +15,7 @@ class Git(codearchiver.core.Module):
return inputUrl.url.endswith('.git')

def __init__(self, inputUrl, extraBranches = {}):
self._inputUrl = inputUrl
self._url = inputUrl.url
super().__init__(inputUrl)
self._extraBranches = extraBranches

def process(self):


Ladataan…
Peruuta
Tallenna