21 lines
785 B
TypeScript
21 lines
785 B
TypeScript
// Metro module 13561 (f13562).
|
|
import UserStore from "../../../../stores/UserStore";
|
|
import * as _Constants from "../../Constants";
|
|
import { RPCCommands } from "../../../../Constants";
|
|
import { createRPCCommand } from "../../../../_bundle/Module13535";
|
|
import transformUser from "../../helpers/transformUser";
|
|
const { RPC_EMBEDDED_APP_SCOPE, RPC_LOCAL_SCOPE, RPC_SCOPE_CONFIG } = _Constants;
|
|
const r25 = {};
|
|
const GET_USER = RPCCommands.GET_USER;
|
|
const GET_USER2 = RPCCommands.GET_USER;
|
|
const scope = {};
|
|
scope[RPC_SCOPE_CONFIG.ANY] = [RPC_EMBEDDED_APP_SCOPE, RPC_LOCAL_SCOPE];
|
|
r25[GET_USER] = createRPCCommand(GET_USER2, {
|
|
scope,
|
|
handler: (a0) => {
|
|
const user = UserStore.getUser(a0.args.id);
|
|
return user != null ? transformUser(user) : null;
|
|
}
|
|
});
|
|
export default r25;
|