]> jfr.im git - erebus.git/blobdiff - modules/urls.py
urls - include AIA usage flag in output
[erebus.git] / modules / urls.py
index 19505b353b62aea88c78e2b6e56355dde5cb075f..3583d16c6bc0bc9a96fd0c52b7581e9c9d9575ff 100644 (file)
@@ -270,7 +270,7 @@ def _do_request(url, try_aia=False):
        except Exception as e:
                return 'Unknown error: %s %r' % (type(e).__name__, e.args)
 
-       return response
+       return response, try_aia
 
 
 def goturl(url):
@@ -280,7 +280,7 @@ def goturl(url):
                        if regex.match(url):
                                return None
 
-       response = _do_request(url)
+       response, used_aia = _do_request(url)
        if isinstance(response, stringbase):
                return response
 
@@ -297,6 +297,9 @@ def goturl(url):
                else:
                        output.append("[no length] ")
 
+       if used_aia:
+               output.append("[AIA] ")
+
        # Try to add title if HTML
        if c_type == 'text/html':
                try: