Browse Source

fix wrong checks of twist data userpost.msg property that leads to applying of language filtering by userpost.rt.msg

readme-update
Simon Grim 9 years ago
parent
commit
a9c8f71ab0
  1. 2
      js/twister_actions.js
  2. 2
      js/twister_timeline.js

2
js/twister_actions.js

@ -445,7 +445,7 @@ function processQuery(req) {
continue; continue;
if ($.Options.filterLang.val !== 'disable' && $.Options.filterLangForSearching.val) { if ($.Options.filterLang.val !== 'disable' && $.Options.filterLangForSearching.val) {
if (userpost.msg !== '') if (typeof userpost.msg === 'string' && userpost.msg !== '')
langFilterData = filterLang(userpost.msg); langFilterData = filterLang(userpost.msg);
else else
langFilterData = filterLang(userpost.rt.msg); langFilterData = filterLang(userpost.rt.msg);

2
js/twister_timeline.js

@ -360,7 +360,7 @@ function willBeHidden(post) {
if (typeof post.userpost.lastk === 'undefined') if (typeof post.userpost.lastk === 'undefined')
return false; return false;
if (post.userpost.rt && typeof post.userpost.rt.msg === 'string' && post.userpost.rt.msg !== '') { if (typeof post.userpost.msg !== 'string' || post.userpost.msg === '') {
// hope it is not too egocentric to overcome hideCloseRtsHour this way // hope it is not too egocentric to overcome hideCloseRtsHour this way
if (post.userpost.rt.n === defaultScreenName) if (post.userpost.rt.n === defaultScreenName)
return false; return false;

Loading…
Cancel
Save