Comment 4 for bug 734769

Revision history for this message
Matt Giuca (mgiuca) wrote :

When I did it in trunk, it was in server, correct? So I think it broke because in data-wrapper it moved to shared.

I think this is an example of where we can't just naively use these data wrapper objects around database objects. We need to consider the use of it on the client. GameFile's contents will only really be used in two situations: by a direct HTTP GET or a direct HTTP POST from an upload box. The GWT will not be involved and its javascript doesn't need access to those files. So they don't need to be exposed to the client at all.

Therefore, move them to GameFileData and don't expose them to client, and this should be solved. The public GameFile constructor can, for the moment, simply take no contents, and create an empty file (I don't think GameFiles will usually be constructed on the client).