finished off some code