Details

    • Type: Bug
    • Status: Resolved (View workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 4.3.0
    • Fix Version/s: 4.5.0
    • Component/s: None
    • Labels:
      None

      Description

      This tasl:

      component {
      
      	function run( required numeric id ) {			
      		print.greenLine( id );
      	}
      
      }
      

      works when called with named args:

      task run taskFile=task target=run :id=5
      

      But errors when called with positional args

      task run task run  5
      
      Can't cast Object type [Array] to a value of type [Struct]
      Java type of the object is lucee.runtime.type.ArrayImpl
      C:\Users\JP\.CommandBox\cfml\system\services\CommandService.cfc: line 972
      970:            for( var param in commandParams ){
      971:                    // If it's required and hasn't been supplied...
      972:                    if( param.required && !structKeyExists( userNamedParams, param.name ) ){
      973:                            // ... Ask the user
      974:                            var message = 'Enter #param.name# ';
      

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                bradwood Brad Wood
                Reporter:
                bradwood Brad Wood
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: