diff --git a/src/config/boomcms/viewHelpers.php b/src/config/boomcms/viewHelpers.php
index <HASH>..<HASH> 100644
--- a/src/config/boomcms/viewHelpers.php
+++ b/src/config/boomcms/viewHelpers.php
@@ -4,15 +4,11 @@ use BoomCMS\Core\Page;
 
 return [
     'viewHelpers' => [
-        'assetURL' => function() {
-			$args = func_get_args();
-			$params = [];
-			
-			if (isset($params['asset'])) {
-				$params['id'] = $asset->getId();
-				unset($params['asset']);
+        'assetURL' => function(array $params) {	
+			if (isset($params['asset']) && is_object($params['asset'])) {
+				$params['asset'] = $params['asset']->getId();
 			}
-			
+
             if ( !isset($params['action'])) {
                 $params['action'] = 'view';
             }
Fixed bugs in $assetURL view helper