Skip to content

Commit 1de23cf

Browse files
author
Happy HumanPointer
authored
Update NSKeyedArchiver.swift
1 parent 5f20cf6 commit 1de23cf

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Foundation/NSKeyedArchiver.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -410,11 +410,11 @@ open class NSKeyedArchiver : NSCoder {
410410
let encodingContext = self._containers.last!
411411
var encodingKey : String
412412

413-
if key != nil {
413+
if let key = key {
414414
if escape {
415-
encodingKey = escapeArchiverKey(key!)
415+
encodingKey = escapeArchiverKey(key)
416416
} else {
417-
encodingKey = key!
417+
encodingKey = key
418418
}
419419
} else {
420420
encodingKey = _nextGenericKey()

0 commit comments

Comments
 (0)