import { KibanaRequest } from 'kibana/server' ; import { SecurityPluginSetup } from '../../../../security/server' ; export function getUser ( request , security ? ) { return security ?. authc . getCurrentUser ( request ) ?? false ; }