Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update regex for notebooks reports
Browse files Browse the repository at this point in the history
Signed-off-by: Joshua Li <[email protected]>
joshuali925 committed Jul 9, 2021

Unverified

This commit is not signed, but one or more authors requires that any commit attributed to them is signed.
1 parent c0b29d3 commit 54740f5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dashboards-reports/server/utils/validationHelper.ts
Original file line number Diff line number Diff line change
@@ -55,7 +55,7 @@ export const isValidRelativeUrl = (relativeUrl: string) => {
export const regexDuration = /^(-?)P(?=\d|T\d)(?:(\d+)Y)?(?:(\d+)M)?(?:(\d+)([DW]))?(?:T(?:(\d+)H)?(?:(\d+)M)?(?:(\d+(?:\.\d+)?)S)?)?$/;
export const regexEmailAddress = /\S+@\S+\.\S+/;
export const regexReportName = /^[\w\-\s\(\)\[\]\,\_\-+]+$/;
export const regexRelativeUrl = /^\/(_plugin\/kibana\/app|app)\/(dashboards|visualize|discover|notebooks-dashboards\?view=output_only)(\?security_tenant=.+|)#\/(view\/|edit\/)?[^\/]+$/;
export const regexRelativeUrl = /^\/(_dashboards\/app|app)\/(dashboards|visualize|discover|notebooks-dashboards\?view=output_only)([?&]security_tenant=.+|)#\/(view\/|edit\/)?[^\/]+$/;

export const validateReport = async (
client: ILegacyScopedClusterClient,

0 comments on commit 54740f5

Please sign in to comment.