aboutsummaryrefslogtreecommitdiff
path: root/xcode/OLMKit/OLMMessage.m
diff options
context:
space:
mode:
Diffstat (limited to 'xcode/OLMKit/OLMMessage.m')
-rw-r--r--xcode/OLMKit/OLMMessage.m11
1 files changed, 11 insertions, 0 deletions
diff --git a/xcode/OLMKit/OLMMessage.m b/xcode/OLMKit/OLMMessage.m
index ce732ec..d0cfb41 100644
--- a/xcode/OLMKit/OLMMessage.m
+++ b/xcode/OLMKit/OLMMessage.m
@@ -10,4 +10,15 @@
@implementation OLMMessage
+- (nullable instancetype) initWithCiphertext:(nonnull NSString*)ciphertext type:(OLMMessageType)type {
+ NSParameterAssert(ciphertext != nil);
+ self = [super init];
+ if (!self) {
+ return nil;
+ }
+ _ciphertext = [ciphertext copy];
+ _type = type;
+ return self;
+}
+
@end