mirror of
https://github.com/AsamK/signal-cli
synced 2025-09-02 20:40:38 +00:00
uploadStickerPath returns String
also, any zip file must be in the same directory as the manifest.json update documentation
This commit is contained in:
parent
d8e5ab5f20
commit
e193bafb8c
3 changed files with 6 additions and 5 deletions
|
@ -457,8 +457,9 @@ verifyWithPin(number<s>, verificationCode<s>, pin<s>) -> <>::
|
|||
|
||||
Exception: Failure, InvalidNumber
|
||||
|
||||
uploadStickerPack(stickerPackPath<s>) -> <>::
|
||||
* stickerPackPath : Path to the sticker pack zip file or manifest.json file
|
||||
uploadStickerPack(stickerPackPath<s>) -> url<s>::
|
||||
* stickerPackPath : Path to the manifest.json file or a zip file in the same directory
|
||||
* url : URL of sticker pack after successful upload
|
||||
|
||||
Exception: Failure
|
||||
|
||||
|
|
|
@ -245,7 +245,7 @@ public interface Signal extends DBusInterface {
|
|||
|
||||
void joinGroup(final String groupLink) throws Error.Failure;
|
||||
|
||||
void uploadStickerPack(String stickerPackPath) throws Error.Failure;
|
||||
String uploadStickerPack(String stickerPackPath) throws Error.Failure;
|
||||
|
||||
class MessageReceived extends DBusSignal {
|
||||
|
||||
|
|
|
@ -1595,11 +1595,11 @@ public class DbusSignalImpl implements Signal {
|
|||
}
|
||||
|
||||
@Override
|
||||
public void uploadStickerPack(String stickerPackPath) {
|
||||
public String uploadStickerPack(String stickerPackPath) {
|
||||
File path = new File(stickerPackPath);
|
||||
|
||||
try {
|
||||
var url = m.uploadStickerPack(path);
|
||||
return m.uploadStickerPack(path);
|
||||
} catch (IOException e) {
|
||||
throw new Error.Failure("Upload error (maybe image size is too large):" + e.getMessage());
|
||||
} catch (StickerPackInvalidException e) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue