mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-20 16:15:59 +01:00
Add another variant of transformation of offline_msg in mod_offline_mnesia
This commit is contained in:
parent
9ec69b8d62
commit
07ef1775cd
@ -168,9 +168,14 @@ need_transform({offline_msg, {U, S}, _, _, _, _, _})
|
||||
when is_list(U) orelse is_list(S) ->
|
||||
?INFO_MSG("Mnesia table 'offline_msg' will be converted to binary", []),
|
||||
true;
|
||||
need_transform({offline_msg, _, _, _, _, _, _, _}) ->
|
||||
true;
|
||||
need_transform(_) ->
|
||||
false.
|
||||
|
||||
transform({offline_msg, {U, S}, Timestamp, Expire, From, To, _, Packet}) ->
|
||||
#offline_msg{us = {U, S}, timestamp = Timestamp, expire = Expire,
|
||||
from = From ,to = To, packet = Packet};
|
||||
transform(#offline_msg{us = {U, S}, from = From, to = To,
|
||||
packet = El} = R) ->
|
||||
R#offline_msg{us = {iolist_to_binary(U), iolist_to_binary(S)},
|
||||
|
Loading…
Reference in New Issue
Block a user