Some logic updates