# All files / js/actions/App/Http/Controllers/Auth VerifyEmailController.ts

0% Statements 0/20
0% Branches 0/7
0% Functions 0/7
0% Lines 0/14

Press n or j to go to the next uncovered block, b, p or k for the previous block.

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97

     import { queryParams, type RouteQueryOptions, type RouteDefinition, type RouteFormDefinition, applyUrlDefaults } from './../../../../../wayfinder'
    /**
    * @see \App\Http\Controllers\Auth\VerifyEmailController::__invoke
     * @see app/Http/Controllers/Auth/VerifyEmailController.php:14
     * @route '/verify-email/{id}/{hash}'
     */
    const VerifyEmailController = (args: { id: string | number, hash: string | number } | [id: string | number, hash: string | number ], options?: RouteQueryOptions): RouteDefinition<'get'> => ({
        url: VerifyEmailController.url(args, options),
        method: 'get',
    })

    VerifyEmailController.definition = {
        methods: ["get","head"],
        url: '/verify-email/{id}/{hash}',
    } satisfies RouteDefinition<["get","head"]>

    /**
    * @see \App\Http\Controllers\Auth\VerifyEmailController::__invoke
     * @see app/Http/Controllers/Auth/VerifyEmailController.php:14
     * @route '/verify-email/{id}/{hash}'
     */
    VerifyEmailController.url = (args: { id: string | number, hash: string | number } | [id: string | number, hash: string | number ], options?: RouteQueryOptions) => {
        if (Array.isArray(args)) {
            args = {
                        id: args[0],
                        hash: args[1],
                    }
        }

        args = applyUrlDefaults(args)

        const parsedArgs = {
                            id: args.id,
                                    hash: args.hash,
                    }

        return VerifyEmailController.definition.url
                .replace('{id}', parsedArgs.id.toString())
                .replace('{hash}', parsedArgs.hash.toString())
                .replace(/\/+$/, '') + queryParams(options)
    }

    /**
    * @see \App\Http\Controllers\Auth\VerifyEmailController::__invoke
     * @see app/Http/Controllers/Auth/VerifyEmailController.php:14
     * @route '/verify-email/{id}/{hash}'
     */
    VerifyEmailController.get = (args: { id: string | number, hash: string | number } | [id: string | number, hash: string | number ], options?: RouteQueryOptions): RouteDefinition<'get'> => ({
        url: VerifyEmailController.url(args, options),
        method: 'get',
    })
    /**
    * @see \App\Http\Controllers\Auth\VerifyEmailController::__invoke
     * @see app/Http/Controllers/Auth/VerifyEmailController.php:14
     * @route '/verify-email/{id}/{hash}'
     */
    VerifyEmailController.head = (args: { id: string | number, hash: string | number } | [id: string | number, hash: string | number ], options?: RouteQueryOptions): RouteDefinition<'head'> => ({
        url: VerifyEmailController.url(args, options),
        method: 'head',
    })

        /**
    * @see \App\Http\Controllers\Auth\VerifyEmailController::__invoke
     * @see app/Http/Controllers/Auth/VerifyEmailController.php:14
     * @route '/verify-email/{id}/{hash}'
     */
        const VerifyEmailControllerForm = (args: { id: string | number, hash: string | number } | [id: string | number, hash: string | number ], options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
            action: VerifyEmailController.url(args, options),
            method: 'get',
        })

                /**
    * @see \App\Http\Controllers\Auth\VerifyEmailController::__invoke
     * @see app/Http/Controllers/Auth/VerifyEmailController.php:14
     * @route '/verify-email/{id}/{hash}'
     */
            VerifyEmailControllerForm.get = (args: { id: string | number, hash: string | number } | [id: string | number, hash: string | number ], options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
                action: VerifyEmailController.url(args, options),
                method: 'get',
            })
                /**
    * @see \App\Http\Controllers\Auth\VerifyEmailController::__invoke
     * @see app/Http/Controllers/Auth/VerifyEmailController.php:14
     * @route '/verify-email/{id}/{hash}'
     */
            VerifyEmailControllerForm.head = (args: { id: string | number, hash: string | number } | [id: string | number, hash: string | number ], options?: RouteQueryOptions): RouteFormDefinition<'get'> => ({
                action: VerifyEmailController.url(args, {
                            [options?.mergeQuery ? 'mergeQuery' : 'query']: {
                                _method: 'HEAD',
                                ...(options?.query ?? options?.mergeQuery ?? {}),
                            }
                        }),
                method: 'get',
            })

        VerifyEmailController.form = VerifyEmailControllerForm
    export default VerifyEmailController