Run before methods for command tasks