parent
08f0d0cb7e
commit
9bbaf79575
@ -37,7 +37,7 @@
|
|||||||
"version": 6,
|
"version": 6,
|
||||||
"params": {
|
"params": {
|
||||||
"filename": "_hello.txt",
|
"filename": "_hello.txt",
|
||||||
"file": "/path/to/file"
|
"path": "/path/to/file"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
@ -475,7 +475,7 @@ class AnkiConnect:
|
|||||||
if data:
|
if data:
|
||||||
self.deleteMediaFile(filename)
|
self.deleteMediaFile(filename)
|
||||||
self.media().writeData(filename, base64.b64decode(data))
|
self.media().writeData(filename, base64.b64decode(data))
|
||||||
elif file:
|
elif path:
|
||||||
self.deleteMediaFile(filename)
|
self.deleteMediaFile(filename)
|
||||||
with open(path, 'rb') as f:
|
with open(path, 'rb') as f:
|
||||||
data = f.read()
|
data = f.read()
|
||||||
|
Loading…
Reference in New Issue
Block a user