runtime: remove unnecessary intermediate type, Status

Signed-off-by: Burcu Dogan <jbd@google.com>
This commit is contained in:
Burcu Dogan 2016-01-27 14:19:10 -08:00 committed by Burcu Dogan
parent 1ade1f6d81
commit 167219101f
5 changed files with 11 additions and 20 deletions

View file

@ -12,8 +12,8 @@ func (h *UpdateEvent) Handle(e *Event) error {
return ErrContainerNotFound
}
container := i.container
if e.State.Status != "" {
switch e.State.Status {
if e.State != "" {
switch e.State {
case runtime.Running:
if err := container.Resume(); err != nil {
return ErrUnknownContainerStatus