diff options
Diffstat (limited to 'OpenSim/Servers/User/UserServerConnector.cs')
-rw-r--r-- | OpenSim/Servers/User/UserServerConnector.cs | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/OpenSim/Servers/User/UserServerConnector.cs b/OpenSim/Servers/User/UserServerConnector.cs index c20cc31..15b09bc 100644 --- a/OpenSim/Servers/User/UserServerConnector.cs +++ b/OpenSim/Servers/User/UserServerConnector.cs | |||
@@ -25,9 +25,10 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | */ | 26 | */ |
27 | 27 | ||
28 | using System; | ||
28 | using Nini.Config; | 29 | using Nini.Config; |
30 | using OpenSim.Servers.Base; | ||
29 | using OpenSim.Services.Interfaces; | 31 | using OpenSim.Services.Interfaces; |
30 | using OpenSim.Services.UserService; | ||
31 | using OpenSim.Framework.Servers.HttpServer; | 32 | using OpenSim.Framework.Servers.HttpServer; |
32 | 33 | ||
33 | namespace OpenSim.Servers.UserServer | 34 | namespace OpenSim.Servers.UserServer |
@@ -38,7 +39,19 @@ namespace OpenSim.Servers.UserServer | |||
38 | 39 | ||
39 | public UserServiceConnector(IConfigSource config, IHttpServer server) | 40 | public UserServiceConnector(IConfigSource config, IHttpServer server) |
40 | { | 41 | { |
41 | m_UserService = new UserService(config); | 42 | IConfig serverConfig = config.Configs["UserService"]; |
43 | if (serverConfig == null) | ||
44 | throw new Exception("No section 'Server' in config file"); | ||
45 | |||
46 | string userService = serverConfig.GetString("LocalServiceModule", | ||
47 | String.Empty); | ||
48 | |||
49 | if (userService == String.Empty) | ||
50 | throw new Exception("No UserService in config file"); | ||
51 | |||
52 | Object[] args = new Object[] { config }; | ||
53 | m_UserService = | ||
54 | ServerUtils.LoadPlugin<IUserService>(userService, args); | ||
42 | } | 55 | } |
43 | } | 56 | } |
44 | } | 57 | } |