CBD-1062:  supply missing "end" to "if"

Change-Id: I19373d730e6caa4a1dc50f4bd2a8ab78f3ed1690
Reviewed-on: http://review.couchbase.org/28445
Reviewed-by: Philip Labee <philip@couchbase.com>
Tested-by: Philip Labee <philip@couchbase.com>