new fn in DOGMA + cleanup