// Public Action methods int PublicAction::onRead(ServerContext& ctxt, FileServer& server, const char *path, string& contents) { string dir; dir_name(path, dir); dir += "/.inetfs_public"; SingleFile file(ctxt, server, path); contents = (!server.isPrivate() || file.exists()) ? "1\n" : "0\n"; return 2; }