<commit_before><?php
namespace Tuum\Web\Controller;

trait ResourceControllerTrait
{
    use RouteDispatchTrait;

    protected $routes = [
        'get:/'           => 'index',
        'get:/create'     => 'create',
        'post:/'          => 'post',
        'get:/{id}'       => 'get',
        'put:/{id}'       => 'put',
        'get:/{id}/edit'  => 'edit',
        'post:/{id}'      => 'update',
        'delete:/{id}'    => 'delete',
    ];

    /**<commit_msg>just thought using only get/post methods to represent resource methods.<commit_after><?php
namespace Tuum\Web\Controller;

trait ResourceControllerTrait
{
    use RouteDispatchTrait;

    protected $routes = [
        'get:/create'       => 'create',
        'get:/{id}/edit'    => 'edit',
        'get:/{id}'         => 'get',
        'get:/'             => 'index',
        'post:/{id}/delete' => 'delete',
        'post:/{id}'        => 'update',
        'post:/'            => 'insert',
    ];

    /**
{'fraction_non_alphanumeric': 0.19917864476386038, 'fraction_numerical': 0.0, 'mean_word_length': 1.7387640449438202, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 18, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7578079', 'n_tokens_mistral': 304, 'n_tokens_neox': 304, 'n_words': 57}