iRessources / AgileDwarf

Agile plugin for Redmine
120 stars 83 forks source link

Fixes a null pointer issue. #41

Closed codingjoe closed 12 years ago

codingjoe commented 12 years ago

The input never got created, therefor you'd get a null pointer exception in line 5 which is now line 6. $('') is not just slower but doesn't allow any attributes. This should be faster and work just fine in any browser.

bcmedeiros commented 12 years ago

Applying your patch or not, I get the following error: Uncaught TypeError: Object [object Object] has no method 'textPlaceholder'

I need to comment out the line 'input.textPlaceholder();' to have the input fields working, but don't really know if comment this line could cause any side-effect.

codingjoe commented 12 years ago

Oh, that's true. I didn't even look into that issue. I think you can drop that line. I can't find any reference for that method. Besides the placeholder gets set before that.

codingjoe commented 12 years ago

Ok, even this, doesn't fix the issue. I found the reference to textPlaceholder()... there is a file with the exact same name ...

Whatever, I did some debugging and the code, even the original one should work just fine.

Apparently there an jQuery issue. jQuery doesn't seem to work. I don't know why and why just for the last script that gets embedded.

However it's impossible to run any jQuery in that file.

I will close this pull request, but the ticket is serious and needs some fixing, as it destroys the entire jeditable functionality. I can't do too much debugging without replacing all the minified scripts, which I can't do due to time issues.

I hope though that this might help you to fix (soon).

Cheers, John

bcmedeiros commented 11 years ago

The workaround suggested by Saruqui on #34 fixes this issue, I don't know how. Do you understand that?