From 527ea375400cf74f5873db76ef5efcf39952ec61 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Fri, 6 Nov 2015 05:18:54 +0000 Subject: [PATCH] change OfflineMessageModule from new avination code to original master, for compatibility with current web servers php scripts. This may change after current test phase --- .../InstantMessage/OfflineMessageModule.cs | 24 +++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/OpenSim/Region/CoreModules/Avatar/InstantMessage/OfflineMessageModule.cs b/OpenSim/Region/CoreModules/Avatar/InstantMessage/OfflineMessageModule.cs index ac89f52940..369d48071d 100644 --- a/OpenSim/Region/CoreModules/Avatar/InstantMessage/OfflineMessageModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/InstantMessage/OfflineMessageModule.cs @@ -248,16 +248,22 @@ namespace OpenSim.Region.CoreModules.Avatar.InstantMessage if (scene == null) scene = m_SceneList[0]; - SendReply reply = SynchronousRestObjectRequester.MakeRequest( - "POST", m_RestURL+"/SaveMessage/?scope=" + - scene.RegionInfo.ScopeID.ToString(), im); +// Avination new code +// SendReply reply = SynchronousRestObjectRequester.MakeRequest( +// "POST", m_RestURL+"/SaveMessage/?scope=" + +// scene.RegionInfo.ScopeID.ToString(), im); + +// current opensim and osgrid compatible + bool success = SynchronousRestObjectRequester.MakeRequest( + "POST", m_RestURL+"/SaveMessage/", im, 10000); +// current opensim and osgrid compatible end if (im.dialog == (byte)InstantMessageDialog.MessageFromAgent) { IClientAPI client = FindClient(new UUID(im.fromAgentID)); if (client == null) return; - +/* Avination new code if (reply.Message == String.Empty) reply.Message = "User is not logged in. " + (reply.Success ? "Message saved." : "Message not saved"); @@ -290,6 +296,16 @@ namespace OpenSim.Region.CoreModules.Avatar.InstantMessage reply.Message, false, new Vector3())); } +*/ +// current opensim and osgrid compatible + client.SendInstantMessage(new GridInstantMessage( + null, new UUID(im.toAgentID), + "System", new UUID(im.fromAgentID), + (byte)InstantMessageDialog.MessageFromAgent, + "User is not logged in. "+ + (success ? "Message saved." : "Message not saved"), + false, new Vector3())); +// current opensim and osgrid compatible end } } }