summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@server-speed.net>2011-06-03 22:57:56 +0200
committerFlorian Pritz <bluewind@server-speed.net>2011-06-03 22:57:56 +0200
commit73928f158c01da3edd20f7ef55afa7ec154142ff (patch)
tree5af6fd82f432e51b29df6d6991a74ec8b528dc81
parent6a7da5c15e79d70d3f866bd0d3467103eb6e84d1 (diff)
simplify curl calls
Signed-off-by: Florian Pritz <bluewind@server-speed.net>
-rw-r--r--fb.in8
1 files changed, 2 insertions, 6 deletions
diff --git a/fb.in b/fb.in
index 40f4258..d4d60cf 100644
--- a/fb.in
+++ b/fb.in
@@ -159,13 +159,9 @@ if [ "$DELETE" ] || [ "$GET" ]; then
for i in "$@"; do
i=$(id_from_arg "$i")
if [ "$DELETE" ]; then
- if ! curl -n -L -A $USERAGENT "$PASTEBIN/file/delete/$i"; then
- EXITCODE=1
- fi
+ curl -n -L -A $USERAGENT "$PASTEBIN/file/delete/$i" || EXITCODE=1
elif [ "$GET" ]; then
- if ! curl -s -o - -A $USERAGENT "$PASTEBIN/$i"; then
- EXITCODE=1
- fi
+ curl -s -o - -A $USERAGENT "$PASTEBIN/$i" || EXITCODE=1
fi
done
elif [ $# -eq 0 ]; then