<commit_before>﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using MongoDB.Bson;
using MongoDB.Driver;
using database_class;
using board_class;
using user_class;
using product_class;

public partial class inspiration : System.Web.UI.Page
{
    database myDB;
    string boardName;
    user curUser;
    IMongoCollection<board_item> usersBoardColl;
    IMongoCollection<user> userInfoColl;
    user designUser;

    protected void Page_Load(object sender, EventArgs e)
    {
        myDB = (database)Session["myDB"];
        boardName = (string)Session["boardName"];
        curUser = (user)Session["curUser"];
        designUser = (user)Session["designUser"];
        userInfoColl = myDB.getUserInfoCollection();
        if (curUser.Account_Type == "client")
        {
            usersBoardColl = myDB.getUsersBoardCollection(curUser);
            board_item.loadBoards(usersBoardColl, boardNameList);
        }
        else if (curUser.Account_Type == "designer")
        {
            if (designUser != null)
            {
                usersBoardColl = myDB.getUsersBoardCollection(designUser);
                userNameLbl.Text = designUser.Username;
            }
            else
            {
                usersBoardColl = myDB.getUsersBoardCollection(curUser);
            }
            userPnl.Visible = true;
            switchUserBtn.Visible = true;
            user.loadUsers(userInfoColl, designerUserList, curUser);
        }
        boardNameLbl.Text = boardName;
        userNameLbl.Text = curUser.Username;
        if (boardName != null)
        {
            loadImages(usersBoardColl, boardName);
            inspirationPnl.Visible = true;
        }
        else
        {
            boardPnl.Visible = false;
            if (curUser.Account_Type == "designer")
            {
                switchUserPnl.Visible = true;
            }<commit_msg>fixed inspiration<commit_after>﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using MongoDB.Bson;
using MongoDB.Driver;
using database_class;
using board_class;
using user_class;
using product_class;

public partial class inspiration : System.Web.UI.Page
{
    database myDB;
    string boardName;
    user curUser;
    IMongoCollection<board_item> usersBoardColl;
    IMongoCollection<user> userInfoColl;
    user designUser;

    protected void Page_Load(object sender, EventArgs e)
    {
        myDB = (database)Session["myDB"];
        boardName = (string)Session["boardName"];
        curUser = (user)Session["curUser"];
        designUser = (user)Session["designUser"];
        userInfoColl = myDB.getUserInfoCollection();
        if (curUser.Account_Type == "client")
        {
            usersBoardColl = myDB.getUsersBoardCollection(curUser);
            board_item.loadBoards(usersBoardColl, boardNameList);
        }
        else if (curUser.Account_Type == "designer")
        {
            if (designUser != null)
            {
                usersBoardColl = myDB.getUsersBoardCollection(designUser);
                userNameLbl.Text = designUser.Username;
            }
            else
            {
                usersBoardColl = myDB.getUsersBoardCollection(curUser);
            }
            userPnl.Visible = true;
            switchUserBtn.Visible = true;
            user.loadUsers(userInfoColl, designerUserList, curUser);
        }
        boardNameLbl.Text = boardName;
        userNameLbl.Text = curUser.Username;
        if (boardName != null)
        {
            loadImages(usersBoardColl, boardName);
            inspirationPnl.Visible = true;
        }
        else
        {
            inspirationPnl.Visible = false;
            boardPnl.Visible = false;
            if (curUser.Account_Type == "designer")
            {
                switchUserPnl.Visible = true;
            }
{'fraction_non_alphanumeric': 0.09170854271356783, 'fraction_numerical': 0.0, 'mean_word_length': 2.1695859872611467, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2598394', 'n_tokens_mistral': 1102, 'n_tokens_neox': 1091, 'n_words': 211}