Skip to content

Commit

Permalink
kazoo: add alternative name for sender
Browse files Browse the repository at this point in the history
  • Loading branch information
lazedo committed Apr 17, 2017
1 parent 1ca7708 commit 7e693ac
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/modules/kazoo/defs.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
#define BLF_JSON_CALLID "Call-ID"
#define BLF_JSON_DIALOGID "Dialog-ID"
#define BLF_JSON_SENDER "Sender-URI"
#define BLF_JSON_SWITCH_URI "Switch-URI"
#define BLF_JSON_ETAG "ETag"
#define BLF_JSON_TOTAG "To-Tag"
#define BLF_JSON_FROMTAG "From-Tag"
Expand Down
4 changes: 4 additions & 0 deletions src/modules/kazoo/kz_pua.c
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,10 @@ int kz_pua_publish_dialoginfo_to_presentity(struct json_object *json_obj)
json_extract_field(BLF_JSON_ETAG, etag);
json_extract_field(BLF_JSON_SENDER, sender);

if (sender.len == 0) {
json_extract_field(BLF_JSON_SWITCH_URI, sender);
}

struct json_object* ExpiresObj = kz_json_get_object(json_obj, BLF_JSON_EXPIRES);
if (ExpiresObj != NULL) {
expires = json_object_get_int(ExpiresObj);
Expand Down

0 comments on commit 7e693ac

Please sign in to comment.