diff options
| author | Sam Wilkins <samwilkins333@gmail.com> | 2019-12-13 17:31:21 -0500 |
|---|---|---|
| committer | Sam Wilkins <samwilkins333@gmail.com> | 2019-12-13 17:31:21 -0500 |
| commit | 4a0cd5a75d6f77067ee5d119012c489d73ffb649 (patch) | |
| tree | 239fa92fe9b01723f284eb66260de90aa56aaa07 /src/client/views/pdf/PDFViewer.tsx | |
| parent | c983198f504eabe45e6b4110283b0f53211622b8 (diff) | |
wrong constructor dammit
Diffstat (limited to 'src/client/views/pdf/PDFViewer.tsx')
| -rw-r--r-- | src/client/views/pdf/PDFViewer.tsx | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/src/client/views/pdf/PDFViewer.tsx b/src/client/views/pdf/PDFViewer.tsx index 648522cd9..e34d353f4 100644 --- a/src/client/views/pdf/PDFViewer.tsx +++ b/src/client/views/pdf/PDFViewer.tsx @@ -121,31 +121,6 @@ export class PDFViewer extends DocAnnotatableComponent<IViewerProps, PdfDocument return this._annotations.filter(anno => this._script.run({ this: anno }, console.log, true).result); } - constructor(props: any) { - super(props); - const backup = "oldPath"; - const { url, Document } = this.props; - const pathCorrectionTest = /upload\_[a-z0-9]{32}.(.*)/g; - const matches = pathCorrectionTest.exec(url); - console.log("\nHere's the { url } being fed into the outer regex:"); - console.log(url); - console.log("And here's the 'properPath' build from the captured filename:\n"); - if (matches !== null) { - const properPath = Utils.prepend(`/files/pdfs/${matches[0]}`); - console.log(properPath); - if (!properPath.includes(url)) { - console.log(`The two (url and proper path) were not equal`); - const proto = Doc.GetProto(Document); - proto[this.props.fieldKey] = new PdfField(properPath); - proto[backup] = url; - } else { - console.log(`The two (url and proper path) were equal`); - } - } else { - console.log("Outer matches was null!"); - } - } - _lastSearch: string = ""; componentDidMount = async () => { !this.props.Document.lockedTransform && (this.props.Document.lockedTransform = true); |
