# GetLatestIsValid(AssetList)

> The task tests the given asset list and returns true if Provider.GetLatest is valid operation for one or more assets.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor.VersionControl](/engine/6000.0/script-reference/unityeditor/versioncontrol.md)
* **Assembly:** UnityEditor

```csharp
public static bool GetLatestIsValid(AssetList assets)
```

### Parameters

**** (\[AssetList]\(/engine/6000.0/script-reference/unityeditor/versioncontrol/assetlist)): List of assets to test.

### Returns

| Type                                                          | Description |
| ------------------------------------------------------------- | ----------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) |             |

### Examples

```csharp
using System.Collections.Generic;
using UnityEditor;
using UnityEditor.VersionControl;
using UnityEngine;

public class EditorScript : MonoBehaviour
{
    [MenuItem("Version Control/GetLatestIsValid")]
    public static void ExampleGetLatestIsValid()
    {
        AssetList assets = new AssetList();
        assets.Add(Provider.GetAssetByPath("Assets/ExampleAsset.cs"));
        assets.Add(Provider.GetAssetByPath("Assets/ExampleAsset.cs.meta"));
        Task t = Provider.GetLatest(assets);
        t.Wait();
    }
}
```
