title: AWS Serverless Error for Provider variables - Trying to populate non string value into a string for variable
body: <p>I am using Serverless framework.</p>
  
  <p>I have created Cognito user pool in one stack and importing it into second stack.</p>
  
  <p>When I assign the value of the Cognito User pool ID created in the first stack, to the environment variable it works.</p>
  
  <p>But when I try to use it while creating a ARN for Cognito Authorizer, it doesn't work.
  I get an error - <strong>Trying to populate non string value into a string for variable</strong></p>
  
  <p>Here is the snippet of my serverless.yml file.</p>
  
  <pre><code>service: myservice
  
  plugins:
    - serverless-pseudo-parameters
  
  provider:
    name: aws
    runtime: go1.x
    stage: dev
    region: us-east-1
  
    cognitoUserPoolId :
      Fn::ImportValue: cloudformation-resources-${self:provider.stage}-CognitoUserPool
    cognitoAppClientId :
      Fn::ImportValue: cloudformation-resources-${self:provider.stage}-CognitoUserPoolClient
  
  
  custom:
  
    environment:
  
      COGNITO_USER_POOL_ID : ${self:provider.cognitoUserPoolId}
      COGNITO_APP_CLIENT_ID: ${self:provider.cognitoAppClientId}
  
  functions:
    myfunction:
      handler: bin/handlers/myfunction
      package:
       exclude:
          - "**/**"
       include:
         - ./bin/handlers/myfunction
      events:         
  
        - http:
              path: mypath
              method: put
              authorizer:
                 name: cognitoapiauthorizer
                 arn: arn:aws:cognito-idp:#{AWS::Region}:#{AWS::AccountId}:userpool/${self:provider.cognitoUserPoolId}
              cors: true
  </code></pre>
  
  <p>Any issues related to indentation or the way it is being used in another variable like ARN?</p>