Latest Updates

Documenting code, one commit at a time.

Validating Livewire Requests with Middleware in the Platform Project

In the Reimpact/platform project, a recent update addresses an issue where Livewire update requests were being incorrectly blocked by a custom middleware. This post details the problem and the solution implemented.

The Problem

The ValidationUserMiddleware was designed to handle user authentication and validation for incoming requests. However, it was inadvertently blocking unauthenticated

Read more

Handling Livewire Requests with Laravel Middleware

The Problem

In a Laravel application, particularly when using Livewire, maintaining consistent authentication behavior across different types of requests can be tricky. A common issue arises when Livewire requests, which often send Content-Type: application/json, are not correctly handled by authentication middleware, leading to unexpected 401 errors instead of redirects to the login page.

Read more

Troubleshooting 401 Errors After Login in Laravel Applications

Introduction

Experiencing a 401 Unauthorized error immediately after a successful login can be a frustrating issue in Laravel applications. This often stems from incorrect redirection targets or misconfigured middleware. Let's explore how to diagnose and resolve such problems, specifically within the context of projects using middleware for access control.

Understanding the Problem

Read more
PHP UX Breniapp

Enhancing Onboarding Flow with Streamlined CTA Selection in Breniapp

This post delves into recent improvements made to the onboarding process in Breniapp, focusing on a more intuitive and user-friendly experience. These changes align the onboarding flow with the Lovable specification, specifically targeting CTA selection and copy style options.

The Challenge

Previously, the process of selecting primary and secondary Call-to-Action (CTA) options during

Read more

Tenant Context Troubles: Debugging Queue Deserialization in a Multi-Tenant Laravel App

In the Reimpact/platform project, we encountered a tricky issue with queue deserialization in our multi-tenant environment. This post details the problem, our investigation, and the solution we implemented.

The Problem

Our application uses a queue to generate reports. A GenerateReportJob is dispatched, serializing the GeneratedReport model.

Read more

Tenant Schema Resetting Too Early: A Laravel Livewire Gotcha

The Reimpact/platform project focuses on providing a multi-tenant application structure. Recently, we encountered an issue with tenant database schemas being reset prematurely during Livewire updates. This post dives into the problem and the solution implemented.

The Problem

In a multi-tenant application, each tenant typically has its own database schema. We use middleware to set the correct

Read more

Ensuring Tenant Context for Filament Uploads in Laravel

Introduction

When building multi-tenant applications with Laravel and Filament, it's crucial to ensure that operations are performed within the correct tenant context. This post addresses a common issue encountered when using Filament's massive upload feature where the tenant context was not active during Livewire form submissions, leading to data integrity violations.

The Problem: Tenant

Read more

Streamlining Filament Forms with Namespace Updates and Tenant Context Resolution

Keeping dependencies up-to-date can be a headache, especially when upgrading major versions of frameworks. Let's look at how recent changes in the Reimpact platform addressed a namespace change in Filament v5 and improved tenant context resolution.

The Challenge: Filament v5 Namespace Update

Filament is a popular Rapid Application Development (RAD) framework for Laravel.

Read more

Enhancing Tenant Management and File Handling in Laravel Applications

Introduction

When building multi-tenant applications with Laravel, ensuring proper tenant context and efficient file handling are critical. Recent updates to the Reimpact platform focus on improving these aspects, streamlining tenant schema management and simplifying large file uploads.

Tenant Schema Isolation Improvements

Proper tenant schema isolation is essential for maintaining data

Read more