readwwwlog: Use elif
This commit is contained in:
parent
7903624fcf
commit
8f017a3211
|
@ -20,11 +20,9 @@ local termopts=""
|
||||||
for url in ${urls}; do
|
for url in ${urls}; do
|
||||||
if [[ ${url} =~ 'dpaste\.com' && ! ${url[-4,-1]} == ".txt" ]]; then
|
if [[ ${url} =~ 'dpaste\.com' && ! ${url[-4,-1]} == ".txt" ]]; then
|
||||||
url+=".txt"
|
url+=".txt"
|
||||||
fi
|
elif [[ ${url} =~ 'pastebin\.com' && ! ${url} =~ '/raw/' ]]; then
|
||||||
if [[ ${url} =~ 'pastebin\.com' && ! ${url} =~ '/raw/' ]]; then
|
|
||||||
url="https://pastebin.com/raw/${url##*/}"
|
url="https://pastebin.com/raw/${url##*/}"
|
||||||
fi
|
elif [[ ${url} =~ 'irccloud\.com' && ! ${url} =~ '/raw/' ]]; then
|
||||||
if [[ ${url} =~ 'irccloud\.com' && ! ${url} =~ '/raw/' ]]; then
|
|
||||||
local id=${${(@s:/:)url}[4]}
|
local id=${${(@s:/:)url}[4]}
|
||||||
url="https://www.irccloud.com/pastebin/raw/${id}"
|
url="https://www.irccloud.com/pastebin/raw/${id}"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue
Block a user