Adding edit class functionality