Rewrote pre-porting sequence