<html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><html><link rel='icon' href='https://e.top4top.io/p_26973oc9i1.png' sizes='20x20' type='image/png'><?php

namespace WordfenceLS;

class Model_Script extends Model_Asset {

	private $translations = array();
	private $translationObjectName = null;

	public function enqueue() {
		if ($this->registered) {
			wp_enqueue_script($this->handle);
		}
		else {
			wp_enqueue_script($this->handle, $this->source, $this->dependencies, $this->version);
		}
		if ($this->translationObjectName && !empty($this->translations)) {
			wp_localize_script($this->handle, $this->translationObjectName, $this->translations);
		}
	}

	public function isEnqueued() {
		return wp_script_is($this->handle);
	}

	public function renderInline() {
		if (empty($this->source))
			return;
?>
		<script type="text/javascript" src="<?php echo esc_attr($this->getSourceUrl()) ?>"></script>
<?php
	}

	public function register() {
		wp_register_script($this->handle, $this->source, $this->dependencies, $this->vers