mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-11-23 10:07:19 +00:00
Fix issue 2850 (#2852)
* Trim tiddler titles imported via JSON Otherwise, it's possible to create a tiddler with a trailing space (or a leading one, I suppose) in its title. TiddlyWiki, in general, trims titles before operating on a tiddler, so having a tiddler with a trailing space ends up making that tiddler, for all intents and purposes, uneditable. Fixes GH #2850 * Signing the CLA
This commit is contained in:
parent
b71583e9d7
commit
847727146e
@ -532,6 +532,7 @@ NavigatorWidget.prototype.handleImportTiddlersEvent = function(event) {
|
||||
// Process each tiddler
|
||||
importData.tiddlers = importData.tiddlers || {};
|
||||
$tw.utils.each(tiddlers,function(tiddlerFields) {
|
||||
tiddlerFields.title = $tw.utils.trim(tiddlerFields.title);
|
||||
var title = tiddlerFields.title;
|
||||
if(title) {
|
||||
incomingTiddlers.push(title);
|
||||
|
@ -317,4 +317,6 @@ Richard Decal, @crypdick, 2017/04/04
|
||||
|
||||
Adrian Morosanu, @morosanuae, 2017/06/02
|
||||
|
||||
Rob Hoelz, @hoelzro, 2017/05/08
|
||||
|
||||
Saq Imtiaz, @saqimtiaz, 2017/06/14
|
||||
|
Loading…
Reference in New Issue
Block a user