removed not working code
changed method how apps are filtered which fixes #2