Small optimization

Signed-off-by: jfarcand <jfarcand@apache.org>