Added Command Pattern and code to diff