Skip to content

Commit e526be5

Browse files
committed
truncate param fix
1 parent 6231345 commit e526be5

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Sources/PrivMXEndpointSwiftNative/NativeStoreApiWrapper.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -371,10 +371,10 @@ ResultWithError<core::Buffer> NativeStoreApiWrapper::readFromFile(StoreFileHandl
371371

372372
ResultWithError<std::nullptr_t> NativeStoreApiWrapper::writeToFile(StoreFileHandle handle,
373373
const core::Buffer& dataChunk,
374-
bool truncate = false){
374+
bool truncate){
375375
ResultWithError<std::nullptr_t> res;
376376
try{
377-
getapi()->writeToFile(handle, dataChunk);
377+
getapi()->writeToFile(handle, dataChunk,truncate);
378378
}catch(core::Exception& err){
379379
res.error = {
380380
.name = err.getName(),

Sources/PrivMXEndpointSwiftNative/include/NativeStoreApiWrapper.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ class NativeStoreApiWrapper{
194194
*/
195195
ResultWithError<std::nullptr_t> writeToFile(const StoreFileHandle handle,
196196
const endpoint::core::Buffer& dataChunk,
197-
bool truncate);
197+
bool truncate=false);
198198

199199
/**
200200
* Reads from an opened file.

0 commit comments

Comments
 (0)