WIP: to null-safety app
This commit is contained in:
		@@ -211,8 +211,23 @@ function escapeCsv(str) {
 | 
			
		||||
	}
 | 
			
		||||
	return result
 | 
			
		||||
}
 | 
			
		||||
function evalAttr(json, attr, lenCk) {
 | 
			
		||||
	if (json[attr]) {
 | 
			
		||||
		if (lenCk) {
 | 
			
		||||
			if (json[attr][0]) {
 | 
			
		||||
				return true
 | 
			
		||||
			} else {
 | 
			
		||||
				return false
 | 
			
		||||
			}
 | 
			
		||||
		} else {
 | 
			
		||||
			return true
 | 
			
		||||
		}
 | 
			
		||||
	} else {
 | 
			
		||||
		return false
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
function statusModel(now) {
 | 
			
		||||
	if(!now){
 | 
			
		||||
	if (!now) {
 | 
			
		||||
		var now = new Date().toString()
 | 
			
		||||
	}
 | 
			
		||||
	return {
 | 
			
		||||
@@ -248,12 +263,10 @@ function statusModel(now) {
 | 
			
		||||
			locked: false,
 | 
			
		||||
			bot: false,
 | 
			
		||||
			created_at: now,
 | 
			
		||||
			note:
 | 
			
		||||
				'',
 | 
			
		||||
			note: '',
 | 
			
		||||
			url: '',
 | 
			
		||||
			avatar: '',
 | 
			
		||||
			avatar_static:
 | 
			
		||||
				'',
 | 
			
		||||
			avatar_static: '',
 | 
			
		||||
			header: '',
 | 
			
		||||
			header_static: '',
 | 
			
		||||
			followers_count: 0,
 | 
			
		||||
 
 | 
			
		||||
@@ -151,7 +151,7 @@ function media(b64, type, no) {
 | 
			
		||||
				mediav = mediav.replace(regExp, json['id'])
 | 
			
		||||
				$('#media').val(mediav)
 | 
			
		||||
			}
 | 
			
		||||
			if (img == 'url') {
 | 
			
		||||
			if (img == 'url' && json['text_url']) {
 | 
			
		||||
				$('#textarea').val($('#textarea').val() + ' ' + json['text_url'])
 | 
			
		||||
			}
 | 
			
		||||
			todc()
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user