@login_required(login_url='/login')
def profile(request, username):
    user = User.objects.get(username=username)
    user_profile = Profile.filter_profile_by_id(user.id)
    projects = Project.objects.filter(user=user_profile)
    ctx = {'user_profile': user_profile, 'user': user, 'projects': projects}
    return render(request, 'profile/profile.html', ctx)
@login_required(login_url='/login')
def profile(request, username):
    user = User.objects.get(username=username)
    user_profile = Profile.filter_profile_by_id(user.id)
    projects = Project.objects.filter(user=user_profile)
    ctx = {'user_profile': user_profile, 'user': user, 'projects': projects}
    return render(request, 'profile/profile.html', ctx)