feat: made boards dynamic and save to the db

This commit is contained in:
limited_dev 2023-03-01 14:44:06 +01:00
parent 8ebc78b754
commit 97e4b0026b
14 changed files with 107 additions and 110 deletions

View file

@ -1,9 +0,0 @@
namespace ImageBoardServerApp.Data;
public class Boards
{
private List<PostData> posts = new List<PostData>()
{
};
}

View file

@ -22,7 +22,7 @@ public class TheManager
public static long getBumpValue(PostData post)
{
return (post.IsSticky ? 999999999999999999 : 10 * 60000 - getDiff(post) + ( 60000 * (post.Comments.Count + 1))) ;
return (post.IsSticky ? 999999999999999999 + getDiff(post) : 10 * 60000 - getDiff(post) + ( 60000 * (post.Comments.Count + 1))) ;
}
public static async Task<List<PostData>> getPostList(string boardTag)