Author: Sami Samiudidn

  • Some ways to improve bug fixing..

    Bugs will happen whether you like it or not. But it pays off to know the type of bugs they are. External bug in an API/service your system relies on? A syntax bug? A logical bug? A bug caused by server itself? The list goes on. But that’s really the first step. You must know…

  • Using Stripe with Laravel/PHP (Stripe connect)

    What we’ll cover: Overview Enabling Stripe-Connect account The On-boarding Process Generating On-boarding Link On-boarding verification Taking Payments Verifying Payments Creating a Refund Listening to Refund events Overview In this post I’m going to go over utilizing Stripe’s-Connect. I’ll try giving you a basic understand of how things tie together rather than going into details. I’ll…

  • Distractions aren’t bad if you can control when you’re distracted!

    You think you’re doing great after a distraction but you’re not. I thought I was! I couldn’t spot the difference in thoughts before or after the distraction so I started taking notes right before I knew I was about to distract myself or there was a meeting coming up. When I came back to the…

  • Avoiding Bugs when working with Percentage (%) values in your application

    The idea is that if we have a proper understanding between frontend and the backend then many serious bugs can be avoided. Let’s take VAT Rate as an example. We have an application that displays percentage on frontend, for example 10%, 20%, 19.5%, 2%, 0.5% VAT etc. Our job is to make sure there’s a…

  • Git rebase — How to clean merge history log and squash commits

    Cleaning up merge mess I have people working on different branches. Each person has made several commits. They’ve then merged their work into master branch. Leaving the master branch with several merge messages along with commits and a confusing graph. When you look at the commit history after merging, it looks like below. Change 1,…

  • How we handled user Invoices background process after downtime

    Most people don’t ever think what will happen to the data if background processes stopped working due to server issues! Especially when the customers are consuming the data on regular bases. What will the application do when the server is back up? continue working as usual? will you have to make manual changes? notify the…

  • How not to ruin your data after downtime

    Sometimes it’s best to create a nice interface for the users and let them fix the state of data instead of “assuming” things and try fixing it yourself after a downtime. For example, let’s say there’s a system running background process which stopped temporarily due to server downtime. 2 days later… The system is back…

  • Bruteforcing a login page without recaptcha

    Most people don’t realize but it’s very easy to Bruteforce login pages and find the correct password. Dictionaries are freely available online, VPS are cheap. Anyone with some coding knowledge can write a program and attack your websites endpoints. What can you do about it? If you’re not using Recaptcha or invalid login rate limiting…

  • Always validate 3rd API data. Here’s why!

    This is what I think, hear me out. Just because the data is coming from a TRUSTED 3rd party API doesn’t mean you blindly trust, store, and let your users consume it. This is because even though the APIs generally return predictable responses there’s a possibility they mess up (even if happens for a minute…

  • Quick note on setting Return Types

    I had a “getLineTotalForSummary” function which returned subtotal, normally used inside a loop. (Basically a user can add multiple line items to an invoice and this function returns the total for each line taking into account few other values). The function worked fine with dummy data but as we put the application on dev and…