mirror of https://github.com/jetkvm/kvm.git
make golintci happy
This commit is contained in:
parent
5a5d4d09fe
commit
1f69b534a5
|
@ -235,13 +235,14 @@ func getInitialVirtualMediaState() (*VirtualMediaState, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: check if it's WebRTC or HTTP
|
// TODO: check if it's WebRTC or HTTP
|
||||||
if diskPath == "" {
|
switch diskPath {
|
||||||
|
case "":
|
||||||
return nil, nil
|
return nil, nil
|
||||||
} else if diskPath == "/dev/nbd0" {
|
case "/dev/nbd0":
|
||||||
initialState.Source = HTTP
|
initialState.Source = HTTP
|
||||||
initialState.URL = "/"
|
initialState.URL = "/"
|
||||||
initialState.Size = 1
|
initialState.Size = 1
|
||||||
} else {
|
default:
|
||||||
initialState.Filename = filepath.Base(diskPath)
|
initialState.Filename = filepath.Base(diskPath)
|
||||||
// get size from file
|
// get size from file
|
||||||
logger.Info().Str("diskPath", diskPath).Msg("getting file size")
|
logger.Info().Str("diskPath", diskPath).Msg("getting file size")
|
||||||
|
|
Loading…
Reference in New Issue