Skip to content

Instantly share code, notes, and snippets.

View wassim's full-sized avatar
🔥
Busy building products

Wassim wassim

🔥
Busy building products
View GitHub Profile
@wassim
wassim / laravel.log
Created February 3, 2023 11:02
spark-team
[2023-02-03 10:59:33] local.ERROR: The attribute [phone] either does not exist or was not retrieved for model [App\Models\Team]. {"userId":1,"exception":"[object] (Illuminate\\Database\\Eloquent\\MissingAttributeException(code: 0): The attribute [phone] either does not exist or was not retrieved for model [App\\Models\\Team]. at /Users/wassim/Sites/laravel/devwizard-app/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasAttributes.php:478)
[stacktrace]
#0 /Users/wassim/Sites/laravel/devwizard-app/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Concerns/HasAttributes.php(458): Illuminate\\Database\\Eloquent\\Model->throwMissingAttributeExceptionIfApplicable('phone')
#1 /Users/wassim/Sites/laravel/devwizard-app/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Model.php(2212): Illuminate\\Database\\Eloquent\\Model->getAttribute('phone')
#2 /Users/wassim/Sites/laravel/devwizard-app/vendor/laravel/cashier/src/Concerns/ManagesCustomer.php(168): Illuminate\\Database\\Eloquent\\M
@wassim
wassim / export_base_meta_from_airtable.js
Last active December 10, 2020 05:37
Export base meta data from Airtable
const fda = ( fields ) => {
let data = []
for(const f of fields ){
data.push(fd(f))
}
return data
}
const fd = ( field ) => {
let data = {

Keybase proof

I hereby claim:

  • I am wassim on github.
  • I am wassim (https://keybase.io/wassim) on keybase.
  • I have a public key ASDWnURoGXbyoI30XicMLa4SnAmjAM5aTkIYhhErpaAf8go

To claim this, I am signing this object:

@wassim
wassim / custom-post-types-activity-widget-wordpress-dashboard.md
Created November 4, 2017 08:34
Add custom post types to "Activity" widget in WordPress Dashboard.
add_filter( 'dashboard_recent_posts_query_args', function ( $query_args ) {
  // Return public built-in posts + custom post types with 'post' capabilities
  $post_types = get_post_types( array( 'public' => true, "capability_type" => "post" ) );
  if ( is_array( $query_args['post_type'] ) ) {
    $query_args['post_type'] = $post_types;
  } else {
    $temp = $post_types;
    $query_args['post_type'] = $temp;
 }
@wassim
wassim / gpg-agent.conf
Created September 29, 2017 09:04
~/.gnupg/gpg-agent.conf
# Connects gpg-agent to the OSX keychain via the brew-installed
# pinentry program from GPGtools. This is the OSX 'magic sauce',
# allowing the gpg key's passphrase to be stored in the login
# keychain, enabling automatic key signing
pinentry-program /usr/local/bin/pinentry-mac
@wassim
wassim / wordpress-add-link-attributes-to-nav-menu.md
Created November 21, 2016 17:31
[WordPress] Add link attributes to nav menu
@wassim
wassim / make-hostname-resolvable-for-scaleway-servers.md
Last active November 21, 2016 17:32
Make hostname resolvable for Scaleway servers
$ sudo vi /etc/hostname
servername (usually scw-xxxxxx)

Save & exit.

$ sudo vi /etc/hosts
127.0.1.1 scw-xxxxxx scw-xxxxxx