attached functionality polished, key checking still to come