|
@@ -569,12 +569,14 @@ let KMPDFDynamicStampNeedAuthorKey1 = "km_pdfview_dynamic_stamp_need_author"
|
|
|
dateFormatterString = dateStyleArray.last
|
|
|
} else {
|
|
|
let index = dateStyleArray.firstIndex(of: dateStyleIndicate)
|
|
|
- if index! > dateStyleArray.count {
|
|
|
- dateComboBox.selectItem(at: dateStyleArray.count - 1)
|
|
|
- dateFormatterString = dateStyleArray.last
|
|
|
- } else {
|
|
|
- dateComboBox.selectItem(at: index!)
|
|
|
- dateFormatterString = dateStyleIndicate
|
|
|
+ if index != nil{
|
|
|
+ if index ?? 0 > dateStyleArray.count {
|
|
|
+ dateComboBox.selectItem(at: dateStyleArray.count - 1)
|
|
|
+ dateFormatterString = dateStyleArray.last
|
|
|
+ } else {
|
|
|
+ dateComboBox.selectItem(at: index ?? 0)
|
|
|
+ dateFormatterString = dateStyleIndicate
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
|