Gateway fixes