isSuccess method created.