Skip to content

Instantly share code, notes, and snippets.

@stijnh92
stijnh92 / S3v2ServiceProvider.php
Last active April 16, 2018 08:04
S3 version 2 compatible storage driver for Laravel 5.1+
<?php
/**
* @file
* Usage:
* 1. remove the V3 AWS PHP sdk when present
* composer remove "league/flysystem-aws-s3-v3"
* 2. install the V3 AWS PHP sdk when present
* composer require "league/flysystem-aws-s3-v2"
* 3. Add the provider to your config/app.php:
@mbertschler
mbertschler / main.go
Created August 13, 2015 15:38
Multithreaded GLFW App with multiple Windows Render Problems
package main
import (
"fmt"
"runtime"
"time"
"github.com/go-gl/gl/v2.1/gl"
"github.com/go-gl/glfw/v3.1/glfw"
)
@baptistedonaux
baptistedonaux / DeletedFilter.php
Created February 19, 2015 11:32
Soft Delete Symfony/Doctrine
<?php
namespace Namespace\MyBundle\Repository\Filters;
use Doctrine\ORM\Mapping\ClassMetaData;
use Doctrine\ORM\Query\Filter\SQLFilter;
class DeletedFilter extends SQLFilter
{
public function addFilterConstraint(ClassMetadata $targetEntity, $targetTableAlias)
{