clean up app code
fix broken spec [skip ci]