src/Object/MediaObject.php
protected function _getObjectSrc($type = 'embed-src') {
		if (empty($this->_stub['id']) || empty($this->_stub['slug'])) {
			return null;
		}

		$stubSrc = $this->_stub[$type];
		if (strpos($stubSrc, '$r2') !== false) {
			$src = str_replace('$r2', $this->_stub['id'], $stubSrc);
		} else {
			$src = str_replace('$2', $this->_stub['id'], $stubSrc);
		}
		if (!empty($host['replace'])) {
			foreach ($host['replace'] as $placeholder => $replacement) {
				$src = str_replace($placeholder, $replacement, $src);
			}
		}
		return $src;
	}
protected function _getObjectSrc($type = 'embed-src') {
		if (empty($this->_stub['id']) || empty($this->_stub['slug'])) {
			return null;
		}

		$stubSrc = $this->_stub[$type];
		if (strpos($stubSrc, '$r2') !== false) {
			$src = str_replace('$r2', $this->_stub['id'], $stubSrc);
		} else {
			$src = str_replace('$2', $this->_stub['id'], $stubSrc);
		}
		if (!empty($host['replace'])) {
			foreach ($host['replace'] as $placeholder => $replacement) {
				$src = str_replace($placeholder, $replacement, $src);
			}
		}
		return $src;
	}
protected function _getObjectSrc ( $ type = 'embed-src' ) { if ( empty ( $ this -> _stub [ 'id' ] ) || empty ( $ this -> _stub [ 'slug' ] ) ) { return null ; } $ stubSrc = $ this -> _stub [ $ type ] ; if ( strpos ( $ stubSrc , '$r2' ) !== false ) { $ src = str_replace ( '$r2' , $ this -> _stub [ 'id' ] , $ stubSrc ) ; } else { $ src = str_replace ( '$2' , $ this -> _stub [ 'id' ] , $ stubSrc ) ; } if ( ! empty ( $ host [ 'replace' ] ) ) { foreach ( $ host [ 'replace' ] as $ placeholder => $ replacement ) { $ src = str_replace ( $ placeholder , $ replacement , $ src ) ; } } return $ src ; }
Get final src

@param string $type
@return string|null
Get final src