Closed
Bug 954956
Opened 11 years ago
Closed 11 years ago
Moving a JS-XMPP buddy from a tag to another should work and save this change on the server
Categories
(Chat Core :: XMPP, defect)
Chat Core
XMPP
Tracking
(Not tracked)
RESOLVED
FIXED
1.2
People
(Reporter: florian, Assigned: florian)
References
Details
(Whiteboard: [1.2-wanted])
Attachments
(1 file, 1 obsolete file)
3.67 KB,
patch
|
clokep
:
review+
|
Details | Diff | Splinter Review |
*** Original post on bio 1524 at 2012-06-19 21:10:00 UTC ***
This worked with the libpurple prpl. We need to implement the tag setter on the prplIAccountBuddy implementation of JS-XMPP. This shouldn't be too difficult.
Assignee | ||
Updated•11 years ago
|
Whiteboard: [1.2-wanted]
Assignee | ||
Comment 1•11 years ago
|
||
*** Original post on bio 1524 as attmnt 1783 at 2012-08-03 23:27:00 UTC ***
This mostly works, but when we receive a tag change from the server, the contact appears in the new tag in the buddy list window, but doesn't disappear from the old one; and after a restart it has both tags. I'm too tired to debug this now, but I figured it would help to show you the patch earlier so that you can familiarize yourself a bit with it before the review request.
Attachment #8353544 -
Flags: feedback?(clokep)
Assignee | ||
Updated•11 years ago
|
Assignee: nobody → florian
Comment 2•11 years ago
|
||
Comment on attachment 8353544 [details] [diff] [review]
WIP
*** Original change on bio 1524 attmnt 1783 at 2012-08-04 14:23:11 UTC ***
>diff --git a/chat/protocols/xmpp/xmpp.jsm b/chat/protocols/xmpp/xmpp.jsm
>+ get tag() this._tag,
>+ set tag(aNewTag) {
>+ let oldTag = this._tag;
>+ this._tag = aNewTag;
Shouldn't we check here if the tags are the same before trying to move the buddy?
>+ Services.contacts.accountBuddyMoved(this, oldTag, aNewTag);
>+ if (!this._rosterItem) {
>+ ERROR("attempting to change the tag of an account buddy without roster item");
>+ return;
>+ }
Besides that it looks fairly good. I don't have any major comments.
Attachment #8353544 -
Flags: feedback?(clokep) → feedback+
Assignee | ||
Comment 3•11 years ago
|
||
*** Original post on bio 1524 as attmnt 1789 at 2012-08-05 01:37:00 UTC ***
Addressed your comment.
Attachment #8353548 -
Flags: review?(clokep)
Assignee | ||
Comment 4•11 years ago
|
||
Comment on attachment 8353544 [details] [diff] [review]
WIP
*** Original change on bio 1524 attmnt 1783 at 2012-08-05 01:37:00 UTC was without comment, so any subsequent comment numbers will be shifted ***
Attachment #8353544 -
Attachment is obsolete: true
Assignee | ||
Comment 5•11 years ago
|
||
*** Original post on bio 1524 at 2012-08-05 01:43:01 UTC ***
(In reply to comment #1)
> [...] when we receive a tag change from the server, the
> contact appears in the new tag in the buddy list window, but doesn't disappear
> from the old one; and after a restart it has both tags.
It turns out those were 2 different issues, that I debugged and for which I filed a new bug (bug 955048 (bio 1618)) as it's completely unrelated to the JS-XMPP code.
Comment 6•11 years ago
|
||
Comment on attachment 8353548 [details] [diff] [review]
Patch v2
*** Original change on bio 1524 attmnt 1789 at 2012-08-05 04:31:08 UTC was without comment, so any subsequent comment numbers will be shifted ***
Attachment #8353548 -
Flags: review?(clokep) → review+
Comment 7•11 years ago
|
||
*** Original post on bio 1524 at 2012-08-06 01:57:19 UTC ***
Checked in as http://hg.instantbird.org/instantbird/rev/600d4b3e2af9
Status: NEW → RESOLVED
Closed: 11 years ago
OS: Other → All
Hardware: x86 → All
Resolution: --- → FIXED
Target Milestone: --- → 1.2
You need to log in
before you can comment on or make changes to this bug.
Description
•