parsav  Diff

Differences From Artifact [5c434424ea]:

To Artifact [0ee70a00a0]:


14
15
16
17
18
19
20



21
22
23
24
25
26
27
28
29
30
31
..
97
98
99
100
101
102
103
104


105
106
107
108
109
110


111
112
113
114
115
116
117
	var spec    = lib.str.ref.null()
	if hpath.ct >= 2 then
		modestr = hpath(1)
		if hpath.ct >= 3 then spec = hpath(2) end
	end
	var mode = modes.follow
	var circle: uint64 = 0



	if modestr:ref() then
		if     modestr:cmp('local' ) then mode = [modes['local']]
		elseif modestr:cmp('mutual') then mode = modes.mutual
		elseif modestr:cmp('fedi'  ) then mode = modes.fedi
		elseif modestr:cmp('circle') then mode = modes.circle
		end
	end
	if requires_login(mode) and co.aid == 0 then mode = [modes['local']] end


	var stoptime = lib.osclock.time(nil)
................................................................................
		for i = 0, posts.sz do
			var author = co:uid2actor(posts(i).ptr.author)
			if mode == modes.mutual and posts(i).ptr.author ~= co.who.id then
				if not author.relationship.recip.follow() then goto skip end
			end
			if author.relationship.rel.mute() or 
			   author.relationship.rel.avoid() or 
			   author.relationship.recip.exclude() then goto skip end


			if posts(i).ptr.rtdby ~= 0 then
				var rter = co:uid2actor(posts(i).ptr.rtdby)
				if rter.relationship.rel.mute()
				or rter.relationship.rel.attenuate()
				or rter.relationship.rel.avoid()
				or rter.relationship.recip.exclude() then goto skip end


			end
			lib.render.tweet(co, posts(i).ptr, &acc)
			var t = lib.math.biggest(lib.math.biggest(posts(i).ptr.posted, posts(i).ptr.discovered),posts(i).ptr.edited)
			if t > newest then newest = t end
			::skip:: posts(i):free()
		end
		if posts.run > 0 then posts:free() end







>
>
>

|

|







 







|
>
>





|
>
>







14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
...
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
	var spec    = lib.str.ref.null()
	if hpath.ct >= 2 then
		modestr = hpath(1)
		if hpath.ct >= 3 then spec = hpath(2) end
	end
	var mode = modes.follow
	var circle: uint64 = 0
	var reqPowers: lib.store.powerset
		reqPowers:clear()
		reqPowers.visible = true
	if modestr:ref() then
		if     modestr:cmp('local' ) then mode = [modes['local']] reqPowers.shout = true
		elseif modestr:cmp('mutual') then mode = modes.mutual
		elseif modestr:cmp('fedi'  ) then mode = modes.fedi       reqPowers.shout = true
		elseif modestr:cmp('circle') then mode = modes.circle
		end
	end
	if requires_login(mode) and co.aid == 0 then mode = [modes['local']] end


	var stoptime = lib.osclock.time(nil)
................................................................................
		for i = 0, posts.sz do
			var author = co:uid2actor(posts(i).ptr.author)
			if mode == modes.mutual and posts(i).ptr.author ~= co.who.id then
				if not author.relationship.recip.follow() then goto skip end
			end
			if author.relationship.rel.mute() or 
			   author.relationship.rel.avoid() or 
			   author.relationship.recip.exclude() or
			  (not ((author.rights.powers and reqPowers) == reqPowers))
				 then goto skip end
			if posts(i).ptr.rtdby ~= 0 then
				var rter = co:uid2actor(posts(i).ptr.rtdby)
				if rter.relationship.rel.mute()
				or rter.relationship.rel.attenuate()
				or rter.relationship.rel.avoid()
				or rter.relationship.recip.exclude() 
				or (not ((rter.rights.powers and reqPowers) == reqPowers))
					 then goto skip end
			end
			lib.render.tweet(co, posts(i).ptr, &acc)
			var t = lib.math.biggest(lib.math.biggest(posts(i).ptr.posted, posts(i).ptr.discovered),posts(i).ptr.edited)
			if t > newest then newest = t end
			::skip:: posts(i):free()
		end
		if posts.run > 0 then posts:free() end