mirror of
https://github.com/celogeek/go-comic-converter.git
synced 2025-05-24 07:42:37 +02:00
handle missing profile
This commit is contained in:
parent
5968cbdd09
commit
cc7a97ad6f
@ -241,7 +241,11 @@ func (o *Options) ShowConfig() string {
|
||||
if o.AspectRatio > 0 {
|
||||
aspectRatio = fmt.Sprintf("1:%.02f", o.AspectRatio)
|
||||
} else if o.AspectRatio < 0 {
|
||||
aspectRatio = fmt.Sprintf("1:%0.2f (device)", float64(profile.Height)/float64(profile.Width))
|
||||
if profile != nil {
|
||||
aspectRatio = fmt.Sprintf("1:%0.2f (device)", float64(profile.Height)/float64(profile.Width))
|
||||
} else {
|
||||
aspectRatio = "1:?? (device)"
|
||||
}
|
||||
}
|
||||
|
||||
titlePage := ""
|
||||
|
Loading…
x
Reference in New Issue
Block a user