Finished the DST functions