如何正确使用array_push作为另一个数组的键和值

So I am using this code to push new user IDs into an array but I get

Warning: array_push() expects at least 2 parameters, one given

$post_likes = array(
"Some key" => array(
             'date' => date("d/m/Y"), 
             'IP' => get_client_ip())
             ); 
$new_likes = array(
             'date' => date("d/m/Y"), 
             'IP' => get_client_ip());
array_push($post_likes[$current_user->ID] = $new_likes);

The code works. It pushes new key with array value into the previous array. But still I get that warning. What am I missing?

Instead of using array_push() you can directly do like this-

$post_likes[$current_user->ID] = $new_likes;

A sample hardcoded example:- https://eval.in/1000261

Set your new variable $new_likes as like this:

array_push($post_likes[$current_user->ID] = $new_likes,$new_likes);   //expects at least 2 parameters

More info : http://php.net/manual/en/function.array-push.php

Updated:

I am proffering and suggesting to use @Magnus Eriksson's answer though you have accepted my answer.

So, just use as like below:

$post_likes[$current_user->ID] = $new_likes;