{"id":799,"date":"2022-08-30T15:07:22","date_gmt":"2022-08-30T15:07:22","guid":{"rendered":"https:\/\/unknownerror.org\/index.php\/2013\/11\/09\/problem-about-friend-collection-of-common-programming-errors\/"},"modified":"2022-08-30T15:07:22","modified_gmt":"2022-08-30T15:07:22","slug":"problem-about-friend-collection-of-common-programming-errors","status":"publish","type":"post","link":"https:\/\/unknownerror.org\/index.php\/2022\/08\/30\/problem-about-friend-collection-of-common-programming-errors\/","title":{"rendered":"problem about friend-Collection of common programming errors"},"content":{"rendered":"<ul>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/a6b495308482759d359eb97636fdccb0?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nallo<br \/>\ndatabase django models friend friendship<br \/>\nWhat is the best way to model friendships between users for a social networking site?The possible states are:no Friendship FriendRequest from A to B, B needs to confirm (this is asymmetric) A and B are friends (this is symmetric)now its complicated to choose the models right.My Friends are part of my profilequite obvious, A.profile.friends is a many to many relation to other users.no friendship: B not in A.friends and A not in B.friends A requests friendship with B: B in A.friends F<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/3b7f5c29fba3f539b11661843e1b2abf?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nLee Jae Beom<br \/>\nc++ templates compiler-errors friend template-specialization<br \/>\n#include using namespace std; template class test {T y;public:test(T k) : y(k) {}friend int a(T&amp; x); };template int a(T&amp; x) {cout<\/p>\n<p>user), :method =&gt; :post%&gt;<\/p>\n<p>The following error occurs:NoMethodError in Profiles#showShowing \/Users\/mgoff1\/LOAP_1.2.2\/app\/views\/profiles\/show.html.erb where line #13 raised: undefined method `each&#8217; for nil:NilClass Extracted source (around line #13): 10: 11: 12: 13: 14: 15:<\/p>\n<p>16:<\/p>\n<\/li>\n<\/ul>\n<p id=\"rop\"><small>Originally posted 2013-11-09 22:46:08. <\/small><\/p>","protected":false},"excerpt":{"rendered":"<p>allo database django models friend friendship What is the best way to model friendships between users for a social networking site?The possible states are:no Friendship FriendRequest from A to B, B needs to confirm (this is asymmetric) A and B are friends (this is symmetric)now its complicated to choose the models right.My Friends are part [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-799","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/799","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/comments?post=799"}],"version-history":[{"count":0,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/799\/revisions"}],"wp:attachment":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/media?parent=799"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/categories?post=799"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/tags?post=799"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}