Skip to content
Browse files

Simplify code

  • Loading branch information...
1 parent ac7302c commit 568b3c2f68d241762845a9463377d18267611e13 @iliaal committed May 21, 2011
Showing with 2 additions and 10 deletions.
  1. +2 −10 library.c
View
12 library.c
@@ -453,17 +453,9 @@ PHPAPI void redis_boolean_response(INTERNAL_FUNCTION_PARAMETERS, RedisSock *redi
efree(response);
IF_MULTI_OR_PIPELINE() {
- if (ret == '+') {
- add_next_index_bool(z_tab, 1);
- } else {
- add_next_index_bool(z_tab, 0);
- }
+ add_next_index_bool(z_tab, (ret == '+'));
} else {
- if (ret == '+') {
- RETURN_TRUE;
- } else {
- RETURN_FALSE;
- }
+ RETURN_BOOL((ret == '+'));
}
}

0 comments on commit 568b3c2

Please sign in to comment.
Something went wrong with that request. Please try again.