From 1a30f698a51d72c070e277fd89f897c1c0d841d8 Mon Sep 17 00:00:00 2001 From: hns Date: Sun, 28 Jan 2001 21:10:12 +0000 Subject: [PATCH] return "hopobject" for prototype for untyped objects --- src/helma/framework/core/Application.java | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/helma/framework/core/Application.java b/src/helma/framework/core/Application.java index 3854b393..6c136437 100644 --- a/src/helma/framework/core/Application.java +++ b/src/helma/framework/core/Application.java @@ -275,18 +275,22 @@ public class Application extends UnicastRemoteObject implements IRemoteApp, Runn } } - public Prototype getPrototype (String str) { - return typemgr.getPrototype (str); - } + /** + * Return a prototype for a given node. If the node doesn't specify a prototype, + * return the generic hopobject prototype. + */ public Prototype getPrototype (INode n) { String protoname = n.getPrototype (); if (protoname == null) - return null; - return getPrototype (protoname); + return typemgr.getPrototype ("hopobject"); + return typemgr.getPrototype (protoname); } + /** + * Return the user currently associated with a given Hop session ID. + */ public User getUser (String sessionID) { if (sessionID == null) return null;