To reproduce:
Start a comment
Upload an image
The image markdown is never added to your WIP comment
Bug Report Dump (Auto-generated)
Version 1.14.0 (1230) Device: iPhone X (iOS 11.1.2) TestFlight: true
Hmm can also repro this. The delegate is hooked up, the text view exists. Something weird is going on...
Using sim and personal phone I've not been able to reproduce, to confirm the steps I'm doing is:
I've also tried not tapping leave a comment, and going straight to the upload image (technically this bug: #231) but that also works. I've also tried inserting a comment, and the message is inserted much like a header is π€
@Sherlouk before tapping upload, add some text. Itβll break if there is already text.
Sent with GitHawk
Alright reproduced, the textview's text is being defined correctly.
What I think is happening is the Slack TextViewController's caching mechanism is setting the textView's text to be what it cached on view[Will/Did]Appear but because we've changed the version which isn't cached it's basically just overriding with what it thinks is the correct answer
It doesn't break when you have no text as it skips all of the caching logic
Un-assigning myself as I'm not familiar with the inners of Slacks VC
Edit:// To confirm though nothing to do with upload specifically, just the transition of going from a different VC and trying to modify text. All the correct delegate calls are being made, it has the URL and text and if you put a breakpoint in the 'replace' helper function the text is updated perfectly
I'll rephrase, I didn't wanna just add a super kludgy fix π
Possible solutions:
cacheTextView() as soon as we update itOh that makes βsenseβ! Nice detective work @Sherlouk
Sent with GitHawk
They don't call me Sherlock for the fun of it π
You don't have to link to a Wikipedia article for that π
Sent with GitHawk
I've made the reference before and people have been like who the hell is that π