From 73928f158c01da3edd20f7ef55afa7ec154142ff Mon Sep 17 00:00:00 2001 From: Florian Pritz Date: Fri, 3 Jun 2011 22:57:56 +0200 Subject: simplify curl calls Signed-off-by: Florian Pritz --- fb.in | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'fb.in') 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 -- cgit v1.2.3-24-g4f1b