appdb: makeSafe improvement