edit the functionality for activity creation