-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Reporting] refactor routes files and helpers #30111
[Reporting] refactor routes files and helpers #30111
Conversation
💔 Build Failed |
x-pack/plugins/reporting/export_types/csv/server/lib/generate_csv.js
Outdated
Show resolved
Hide resolved
This is a nice cleanup... what do you think about doing TS for some of this (at least the newer modules)? |
@joelgriffith sure, I can put some of the changes in as TS. I'm hunting down a failing unit test, and then I'll pick that up |
@@ -6,7 +6,7 @@ | |||
|
|||
import _ from 'lodash'; | |||
|
|||
export function createFlattenHit(fields, metaFields, conflictedTypesFields) { | |||
export function createFlattenHit(fields, metaFields, conflictedTypesFields = []) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whoops, looks like there was a unit test expecting this to cause a failure
💔 Build Failed |
💔 Build Failed |
💔 Build Failed |
💔 Build Failed |
💔 Build Failed |
retest |
💔 Build Failed |
💔 Build Failed |
💔 Build Failed |
💔 Build Failed |
💚 Build Succeeded |
@@ -7,8 +7,7 @@ | |||
import { resolve } from 'path'; | |||
import { UI_SETTINGS_CUSTOM_PDF_LOGO } from './common/constants'; | |||
import { mirrorPluginStatus } from '../../server/lib/mirror_plugin_status'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice consolidation here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lovin' that TS flavor! LGTM
* remove unused file * refactor routes files and helpers * default empty array for conflictedTypesFields * minor prettier * remove some unrelated diff * some typescript conversions * more typescripts * more typscript * jobtype is a string * revert some logic change * set payload.headers to undefined + not mutate * fix jest import
* remove unused file * refactor routes files and helpers * default empty array for conflictedTypesFields * minor prettier * remove some unrelated diff * some typescript conversions * more typescripts * more typscript * jobtype is a string * revert some logic change * set payload.headers to undefined + not mutate * fix jest import
* remove unused file * refactor routes files and helpers * default empty array for conflictedTypesFields * minor prettier * remove some unrelated diff * some typescript conversions * more typescripts * more typscript * jobtype is a string * revert some logic change * set payload.headers to undefined + not mutate * fix jest import
server/routes
get_absolute_time
WIP: Hold off until #29977 is merged