Use dbaupp's code suggestions