public function mailer()
	{
		if ( is_null( $this->mailerInstance ) )
		{
			// Once we have create the mailer instance, we will set a container instance
			// on the mailer. This allows us to resolve mailer classes via containers
			// for maximum testability on said classes instead of passing Closures.
			$mailer = new Mailer( ViewFactory::i(), $this->swiftMailer() );

			if ( $queue = UniversalBuilder::resolve( 'queue.connection' ) )
				$mailer->setQueue( $queue );

			// If a "from" address is set, we will set it on the mailer so that all mail
			// messages sent by the applications will utilize the same "from" address
			// on each one, which makes the developer's life a lot more convenient.
			$from = Config::get( 'mail.from' );

			if ( is_array( $from ) && isset( $from['address'] ) )
				$mailer->alwaysFrom( $from['address'], $from['name'] );

			$to = Config::get( 'mail.to' );

			if ( is_array( $to ) && isset( $to['address'] ) )
				$mailer->alwaysTo( $to['address'], $to['name'] );

			$this->mailerInstance = $mailer;
		}

		return $this->mailerInstance;
	}
public function mailer()
	{
		if ( is_null( $this->mailerInstance ) )
		{
			// Once we have create the mailer instance, we will set a container instance
			// on the mailer. This allows us to resolve mailer classes via containers
			// for maximum testability on said classes instead of passing Closures.
			$mailer = new Mailer( ViewFactory::i(), $this->swiftMailer() );

			if ( $queue = UniversalBuilder::resolve( 'queue.connection' ) )
				$mailer->setQueue( $queue );

			// If a "from" address is set, we will set it on the mailer so that all mail
			// messages sent by the applications will utilize the same "from" address
			// on each one, which makes the developer's life a lot more convenient.
			$from = Config::get( 'mail.from' );

			if ( is_array( $from ) && isset( $from['address'] ) )
				$mailer->alwaysFrom( $from['address'], $from['name'] );

			$to = Config::get( 'mail.to' );

			if ( is_array( $to ) && isset( $to['address'] ) )
				$mailer->alwaysTo( $to['address'], $to['name'] );

			$this->mailerInstance = $mailer;
		}

		return $this->mailerInstance;
	}
public function mailer ( ) { if ( is_null ( $ this -> mailerInstance ) ) { // Once we have create the mailer instance, we will set a container instance // on the mailer. This allows us to resolve mailer classes via containers // for maximum testability on said classes instead of passing Closures. $ mailer = new Mailer ( ViewFactory :: i ( ) , $ this -> swiftMailer ( ) ) ; if ( $ queue = UniversalBuilder :: resolve ( 'queue.connection' ) ) $ mailer -> setQueue ( $ queue ) ; // If a "from" address is set, we will set it on the mailer so that all mail // messages sent by the applications will utilize the same "from" address // on each one, which makes the developer's life a lot more convenient. $ from = Config :: get ( 'mail.from' ) ; if ( is_array ( $ from ) && isset ( $ from [ 'address' ] ) ) $ mailer -> alwaysFrom ( $ from [ 'address' ] , $ from [ 'name' ] ) ; $ to = Config :: get ( 'mail.to' ) ; if ( is_array ( $ to ) && isset ( $ to [ 'address' ] ) ) $ mailer -> alwaysTo ( $ to [ 'address' ] , $ to [ 'name' ] ) ; $ this -> mailerInstance = $ mailer ; } return $ this -> mailerInstance ; }
mailer.mailer
mailer . mailer