Fixes 'dm' variable still existing